mirror of
https://github.com/immich-app/immich.git
synced 2026-03-04 09:57:33 +03:00
refactor: config init event for first config load (#13930)
This commit is contained in:
@@ -74,8 +74,9 @@ export class StorageTemplateService extends BaseService {
|
||||
return this._template;
|
||||
}
|
||||
|
||||
@OnEvent({ name: 'config.init' })
|
||||
@OnEvent({ name: 'config.update', server: true })
|
||||
onConfigUpdate({ newConfig }: ArgOf<'config.update'>) {
|
||||
onConfigInitOrUpdate({ newConfig }: ArgOf<'config.init'>) {
|
||||
const template = newConfig.storageTemplate.template;
|
||||
if (!this._template || template !== this.template.raw) {
|
||||
this.logger.debug(`Compiling new storage template: ${template}`);
|
||||
|
||||
Reference in New Issue
Block a user