mirror of
https://github.com/KevinMidboe/immich.git
synced 2025-10-29 17:40:28 +00:00
fix(server): read file permission checks (#3046)
This commit is contained in:
@@ -23,7 +23,7 @@ export class FilesystemProvider implements IStorageRepository {
|
||||
|
||||
async createReadStream(filepath: string, mimeType?: string | null): Promise<ImmichReadStream> {
|
||||
const { size } = await fs.stat(filepath);
|
||||
await fs.access(filepath, constants.R_OK | constants.W_OK);
|
||||
await fs.access(filepath, constants.R_OK);
|
||||
return {
|
||||
stream: createReadStream(filepath),
|
||||
length: size,
|
||||
|
||||
Reference in New Issue
Block a user