mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-06 16:06:56 +00:00
fix global context error message logic error (#11815)
following same file line 91 and github.com/kyverno/kyverno/pkg/globalcontext/store#35 the proper handling should be `!ok` Signed-off-by: Damien Degois <damien@degois.info> Co-authored-by: shuting <shuting@nirmata.com>
This commit is contained in:
parent
37c73f9314
commit
e0fe6ec59a
1 changed files with 1 additions and 1 deletions
|
@ -47,7 +47,7 @@ func NewGCTXLoader(
|
||||||
|
|
||||||
func (g *gctxLoader) HasLoaded() bool {
|
func (g *gctxLoader) HasLoaded() bool {
|
||||||
data, ok := g.gctxStore.Get(g.entry.Name)
|
data, ok := g.gctxStore.Get(g.entry.Name)
|
||||||
if ok {
|
if !ok {
|
||||||
g.logger.Error(fmt.Errorf("failed to get data from global context store"), "failed to get data from global context store")
|
g.logger.Error(fmt.Errorf("failed to get data from global context store"), "failed to get data from global context store")
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue