mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 12:24:38 +03:00
Fix setting pointers corrupting config in memory (#4868)
This commit is contained in:
@@ -273,7 +273,7 @@ func (m *schema45Migrator) migrateConfig(ctx context.Context) error {
|
||||
}
|
||||
|
||||
logger.Infof("Setting blobs storage to %s", defaultStorage.String())
|
||||
c.Set(config.BlobsStorage, defaultStorage)
|
||||
c.SetInterface(config.BlobsStorage, defaultStorage)
|
||||
if err := c.Write(); err != nil {
|
||||
logger.Errorf("Error while writing configuration file: %s", err.Error())
|
||||
}
|
||||
@@ -282,7 +282,7 @@ func (m *schema45Migrator) migrateConfig(ctx context.Context) error {
|
||||
scanDefaults := c.GetDefaultScanSettings()
|
||||
if scanDefaults != nil {
|
||||
scanDefaults.ScanGenerateCovers = true
|
||||
c.Set(config.DefaultScanSettings, scanDefaults)
|
||||
c.SetInterface(config.DefaultScanSettings, scanDefaults)
|
||||
if err := c.Write(); err != nil {
|
||||
logger.Errorf("Error while writing configuration file: %s", err.Error())
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user