1
0
mirror of https://github.com/rancher/norman.git synced 2025-09-23 20:18:51 +00:00

Fix doSchema lock issue

This commit is contained in:
MATSUMOTO TAKEAKI
2021-09-22 14:14:50 +09:00
parent afd06f533c
commit e5b9459adb

View File

@@ -327,11 +327,9 @@ func (s *Schemas) doSchema(version *APIVersion, name string, lock bool) *Schema
if lock {
s.Lock()
defer s.Unlock()
}
schemas, ok := s.schemasByPath[path]
if lock {
s.Unlock()
}
if !ok {
return nil
}