From 9b2a054e5470c395732a0d8f666cee346a543bb3 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 26 Jun 2024 14:20:06 +0200 Subject: [PATCH] Fix lint --- client/src/app/shared/shared-main/video/video.model.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/client/src/app/shared/shared-main/video/video.model.ts b/client/src/app/shared/shared-main/video/video.model.ts index 5bbe5431f..cbfb58ce3 100644 --- a/client/src/app/shared/shared-main/video/video.model.ts +++ b/client/src/app/shared/shared-main/video/video.model.ts @@ -251,7 +251,7 @@ export class Video implements VideoServerModel { } hasSeeAllVideosRight (user: AuthUser) { - return user && user.hasRight(UserRight.SEE_ALL_VIDEOS) + return user?.hasRight(UserRight.SEE_ALL_VIDEOS) } isOwnerOrHasSeeAllVideosRight (user: AuthUser) { @@ -278,8 +278,7 @@ export class Video implements VideoServerModel { } canRunForcedTranscoding (user: AuthUser) { - return this.isLocal && - user && user.hasRight(UserRight.RUN_VIDEO_TRANSCODING) + return this.isLocal && user?.hasRight(UserRight.RUN_VIDEO_TRANSCODING) } hasHLS () {