mirror of
https://github.com/immich-app/immich.git
synced 2025-08-07 09:04:09 -04:00
fix: migration if media location is set (#20532)
This commit is contained in:
parent
8108f50c4e
commit
4d5cd1a6b5
@ -101,6 +101,10 @@ export class StorageService extends BaseService {
|
|||||||
const savedValue = await this.systemMetadataRepository.get(SystemMetadataKey.MediaLocation);
|
const savedValue = await this.systemMetadataRepository.get(SystemMetadataKey.MediaLocation);
|
||||||
let previous = savedValue?.location || '';
|
let previous = savedValue?.location || '';
|
||||||
|
|
||||||
|
if (!previous && this.configRepository.getEnv().storage.mediaLocation) {
|
||||||
|
previous = current;
|
||||||
|
}
|
||||||
|
|
||||||
if (!previous) {
|
if (!previous) {
|
||||||
previous = path.startsWith('upload/') ? 'upload' : '/usr/src/app/upload';
|
previous = path.startsWith('upload/') ? 'upload' : '/usr/src/app/upload';
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user