mirror of
https://github.com/immich-app/immich
synced 2025-11-07 17:27:20 +00:00
fix: migration if media location is set (#20532)
This commit is contained in:
parent
8108f50c4e
commit
4d5cd1a6b5
1 changed files with 4 additions and 0 deletions
|
|
@ -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…
Add table
Add a link
Reference in a new issue