diff --git a/server/src/repositories/asset.repository.ts b/server/src/repositories/asset.repository.ts index ca00245c27..3c1676f24f 100644 --- a/server/src/repositories/asset.repository.ts +++ b/server/src/repositories/asset.repository.ts @@ -838,7 +838,7 @@ export class AssetRepository { ) .$if(!!options.withCoordinates, (qb) => qb.select(['asset_exif.latitude', 'asset_exif.longitude'])) .where('asset.deletedAt', options.isTrashed ? 'is not' : 'is', null) - .$if(options.visibility == undefined, withDefaultVisibility) + .$if(options.visibility === undefined, withDefaultVisibility) .$if(!!options.visibility, (qb) => qb.where('asset.visibility', '=', options.visibility!)) .$if(!!options.bbox, (qb) => { const bbox = options.bbox!; diff --git a/server/src/services/storage-template.service.ts b/server/src/services/storage-template.service.ts index e4f2dcacf7..de731f46c6 100644 --- a/server/src/services/storage-template.service.ts +++ b/server/src/services/storage-template.service.ts @@ -402,8 +402,8 @@ export class StorageTemplateService extends BaseService { const substitutions: Record = { filename, ext: extension, - filetype: asset.type == AssetType.Image ? 'IMG' : 'VID', - filetypefull: asset.type == AssetType.Image ? 'IMAGE' : 'VIDEO', + filetype: asset.type === AssetType.Image ? 'IMG' : 'VID', + filetypefull: asset.type === AssetType.Image ? 'IMAGE' : 'VIDEO', assetId: asset.id, assetIdShort: asset.id.slice(-12), //just throw into the root if it doesn't belong to an album diff --git a/server/src/utils/bytes.ts b/server/src/utils/bytes.ts index 5e476f4dea..67e94c7aca 100644 --- a/server/src/utils/bytes.ts +++ b/server/src/utils/bytes.ts @@ -20,7 +20,7 @@ export function asHumanReadable(bytes: number, precision = 1): string { } } - return `${remainder.toFixed(magnitude == 0 ? 0 : precision)} ${units[magnitude]}`; + return `${remainder.toFixed(magnitude === 0 ? 0 : precision)} ${units[magnitude]}`; } // if an asset is jsonified in the DB before being returned, its buffer fields will be hex-encoded strings