add nil check for mfa enforcement config namespace on login (#20375)
* add nil check for mfa enforcement config ns * move nil check and add changelog
This commit is contained in:
parent
5164069708
commit
0d621ea47e
|
@ -0,0 +1,3 @@
|
|||
```release-note:bug
|
||||
core: prevent panic on login after namespace is deleted that had mfa enforcement
|
||||
```
|
|
@ -1788,7 +1788,8 @@ ECONFIG_LOOP:
|
|||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to find the MFAEnforcementConfig namespace")
|
||||
}
|
||||
if eConfig == nil || (eConfigNS.ID != ns.ID && !ns.HasParent(eConfigNS)) {
|
||||
|
||||
if eConfig == nil || eConfigNS == nil || (eConfigNS.ID != ns.ID && !ns.HasParent(eConfigNS)) {
|
||||
continue
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue