Tolerate NamespaceByID returning (nil,nil) when looking up an mfa enforcement's ns (#17562)
This commit is contained in:
parent
8a624c1264
commit
f94bd10540
|
@ -0,0 +1,3 @@
|
|||
```release-note:bug
|
||||
core: prevent panic during mfa after enforcement's namespace is deleted
|
||||
```
|
|
@ -1693,7 +1693,7 @@ ECONFIG_LOOP:
|
|||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to find the MFAEnforcementConfig namespace")
|
||||
}
|
||||
if eConfigNS.ID != ns.ID && !ns.HasParent(eConfigNS) {
|
||||
if eConfig == nil || (eConfigNS.ID != ns.ID && !ns.HasParent(eConfigNS)) {
|
||||
continue
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue