From 49a41650adb05eda1f199a82e3c5b131efe9fe6e Mon Sep 17 00:00:00 2001 From: Moe Jangda Date: Thu, 3 Oct 2024 22:24:37 -0500 Subject: [PATCH] add nil check --- backend/controller/controller.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/controller/controller.go b/backend/controller/controller.go index b02d64b6dd..e57c44f6fd 100644 --- a/backend/controller/controller.go +++ b/backend/controller/controller.go @@ -1025,7 +1025,7 @@ func (s *Service) callWithRequest( module := verbRef.Module - if currentCaller.Module != module && !verb.IsExported() { + if currentCaller != nil && currentCaller.Module != module && !verb.IsExported() { observability.Calls.Request(ctx, req.Msg.Verb, start, optional.Some("invalid request: verb not exported")) return nil, connect.NewError(connect.CodePermissionDenied, fmt.Errorf("verb %q is not exported", verbRef)) }