diff --git a/src-ui/src/app/components/document-detail/document-detail.component.ts b/src-ui/src/app/components/document-detail/document-detail.component.ts index c430526e3..57cb36393 100644 --- a/src-ui/src/app/components/document-detail/document-detail.component.ts +++ b/src-ui/src/app/components/document-detail/document-detail.component.ts @@ -212,7 +212,7 @@ export class DocumentDetailComponent private componentRouterService = inject(ComponentRouterService) private deviceDetectorService = inject(DeviceDetectorService) private savedViewService = inject(SavedViewService) - private websocketStatusService = inject(WebsocketStatusService) + private readonly websocketStatusService = inject(WebsocketStatusService) @ViewChild('inputTitle') titleInput: TextComponent @@ -460,7 +460,7 @@ export class DocumentDetailComponent let formattedModified = null if (modified) { const parsed = new Date(modified) - if (!isNaN(parsed.getTime())) { + if (!Number.isNaN(parsed.getTime())) { formattedModified = parsed.toLocaleString() } } diff --git a/src-ui/src/app/services/websocket-status.service.ts b/src-ui/src/app/services/websocket-status.service.ts index e2181be97..1711a480a 100644 --- a/src-ui/src/app/services/websocket-status.service.ts +++ b/src-ui/src/app/services/websocket-status.service.ts @@ -95,19 +95,20 @@ export class FileStatus { providedIn: 'root', }) export class WebsocketStatusService { - private settingsService = inject(SettingsService) + private readonly settingsService = inject(SettingsService) private statusWebSocket: WebSocket private consumerStatus: FileStatus[] = [] - private documentDetectedSubject = new Subject() - private documentConsumptionFinishedSubject = new Subject() - private documentConsumptionFailedSubject = new Subject() - private documentDeletedSubject = new Subject() - private documentUpdatedSubject = + private readonly documentDetectedSubject = new Subject() + private readonly documentConsumptionFinishedSubject = + new Subject() + private readonly documentConsumptionFailedSubject = new Subject() + private readonly documentDeletedSubject = new Subject() + private readonly documentUpdatedSubject = new Subject() - private connectionStatusSubject = new Subject() + private readonly connectionStatusSubject = new Subject() private get(taskId: string, filename?: string) { let status =