Skip to content
Snippets Groups Projects
Verified Commit 85c27d07 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

fix: unlock config before hooks called #3

parent 6ac53e42
No related branches found
No related tags found
No related merge requests found
......@@ -18,12 +18,6 @@ func (s *Settings[C]) setConfigInternal(config C, lock bool) *Settings[C] {
s.Lock()
}
defer func() {
if lock {
s.Unlock()
}
}()
defer func() {
if len(changelog) > 0 {
......@@ -40,6 +34,12 @@ func (s *Settings[C]) setConfigInternal(config C, lock bool) *Settings[C] {
}
}()
defer func() {
if lock {
s.Unlock()
}
}()
if err := validateConfig[C](config); err != nil {
s.errors = append(s.errors, err)
return s
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment