From 5e743dc302e70e9835da436fc5e213a8a18bec73 Mon Sep 17 00:00:00 2001 From: Brian Cain Date: Wed, 20 Oct 2021 12:50:37 -0700 Subject: [PATCH] Remove else error check Registries aren't required to have access info funcs, so remove this check and try the build anyway --- internal/core/app_build.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/internal/core/app_build.go b/internal/core/app_build.go index 745c4fd47b7..36431b192cd 100644 --- a/internal/core/app_build.go +++ b/internal/core/app_build.go @@ -177,13 +177,10 @@ func (op *buildOperation) Do(ctx context.Context, log hclog.Logger, app *App, _ return nil, err } } else { - if ra != nil && ra.AccessInfoFunc() == nil { + if ok && ra != nil && ra.AccessInfoFunc() == nil { return nil, status.Error(codes.Internal, "The plugin requested does not "+ "define an AccessInfoFunc() in its Registry plugin. This is an internal "+ "error and should be reported to the author of the plugin.") - } else { - return nil, status.Error(codes.Internal, "The given build operation value "+ - "is not a component.RegistryAccess type.") } } }