diff --git a/apps/judicial-system/backend/src/app/modules/case/case.service.ts b/apps/judicial-system/backend/src/app/modules/case/case.service.ts index 5e701d6fa2a7..b9980ed191fd 100644 --- a/apps/judicial-system/backend/src/app/modules/case/case.service.ts +++ b/apps/judicial-system/backend/src/app/modules/case/case.service.ts @@ -846,8 +846,10 @@ export class CaseService { this.getDeliverProsecutorToCourtMessages(theCase, user), ) } - - private addMessagesForSignedCourtRecordToQueue(theCase: Case, user: TUser) { + private addMessagesForSignedCourtRecordToQueue( + theCase: Case, + user: TUser, + ): Promise { const messages = [] if ( @@ -861,13 +863,8 @@ export class CaseService { }) } - if (messages && messages.length > 0) { - return this.messageService.sendMessagesToQueue(messages) - } - - return + return this.messageService.sendMessagesToQueue(messages) } - private addMessagesForSignedRulingToQueue( theCase: Case, user: TUser,