Skip to content

Commit

Permalink
fix(api): fix a couple of sonar cloud lint issues (#569)
Browse files Browse the repository at this point in the history
  • Loading branch information
aaron-plahn authored Mar 5, 2024
1 parent 2411a3b commit 3a56466
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -304,8 +304,6 @@ export class AudioItem extends Resource implements IRadioPublishableResource {
availableCommandIds.push(`TRANSLATE_LINE_ITEM`);

return availableCommandIds;

return availableCommandIds;
}

private isMIMETypeAllowed(mimeType: MIMEType): boolean {
Expand Down
8 changes: 2 additions & 6 deletions apps/api/src/domain/models/song/song.entity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,17 +104,13 @@ export class Song extends Resource {
}

protected validateComplexInvariants(): InternalError[] {
const allErrors: InternalError[] = [];

const { title } = this;

const titleValidationResult = title.validateComplexInvariants();

const titleValidationErrors = isInternalError(titleValidationResult)
? [titleValidationResult]
: [];
const allErrors = isInternalError(titleValidationResult) ? [titleValidationResult] : [];

return allErrors.concat(titleValidationErrors);
return allErrors;
}

protected getExternalReferences(): AggregateCompositeIdentifier[] {
Expand Down

0 comments on commit 3a56466

Please sign in to comment.