1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-24 15:59:41 +02:00

fix(boltdb): upgrade to the latest version to avoid problems with the race detector EE-2729 (#6638)

This commit is contained in:
andres-portainer 2022-03-18 13:16:31 -03:00 committed by GitHub
parent d962c300f9
commit a66e863646
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 17 deletions

View file

@ -22,23 +22,18 @@ func (store *Store) Init() error {
return err
}
err = store.checkOrCreateDefaultData()
if err != nil {
return err
}
return nil
return store.checkOrCreateDefaultData()
}
func (store *Store) checkOrCreateInstanceID() error {
instanceID, err := store.VersionService.InstanceID()
_, err := store.VersionService.InstanceID()
if store.IsErrObjectNotFound(err) {
uid, err := uuid.NewV4()
if err != nil {
return err
}
instanceID = uid.String()
instanceID := uid.String()
return store.VersionService.StoreInstanceID(instanceID)
}
return err