From 49c9c422fe730ae8a2477a404ef21dcee88cb062 Mon Sep 17 00:00:00 2001 From: Alex Snaps Date: Thu, 24 Oct 2024 13:06:06 -0400 Subject: [PATCH] Trying to fix things Signed-off-by: Alex Snaps --- pkg/evaluators/identity/plain.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/evaluators/identity/plain.go b/pkg/evaluators/identity/plain.go index c6bc5ee0..b44d7824 100644 --- a/pkg/evaluators/identity/plain.go +++ b/pkg/evaluators/identity/plain.go @@ -18,10 +18,10 @@ type Plain struct { } func (p *Plain) Call(pipeline auth.AuthPipeline, ctx context.Context) (interface{}, error) { - if object, err := p.Value.ResolveFor(pipeline.GetAuthorizationJSON()); object != nil { - return object, nil - } else if err != nil { + if object, err := p.Value.ResolveFor(pipeline.GetAuthorizationJSON()); err != nil { return nil, err + } else if object != nil { + return object, nil } return nil, fmt.Errorf("could not retrieve identity object or null") }