mirror of
https://github.com/datarhei/core.git
synced 2025-10-05 07:57:13 +08:00
Fix config timestamps
created_at represents the time when the configuration has been persisted to disk. loaded_at represents the time when the configuration has actually been used. If created_at is larger than loaded_at, then the Core needs a reload in order to apply the latest configuration. if created_at is lower than laoded_at, then the Core applied the latest configuration. The value of updated_at is irrelevant and shouldn't be used.
This commit is contained in:
@@ -257,6 +257,8 @@ func (a *api) Reload() error {
|
||||
return fmt.Errorf("not all variables are set or valid")
|
||||
}
|
||||
|
||||
cfg.LoadedAt = time.Now()
|
||||
|
||||
store.SetActive(cfg)
|
||||
|
||||
a.config.store = store
|
||||
|
Reference in New Issue
Block a user