From eb7601d84150fe3b8716a88670ce170ef17a9b83 Mon Sep 17 00:00:00 2001 From: Scott Bishel Date: Tue, 11 Oct 2022 13:34:33 -0600 Subject: [PATCH] GH-3992 fix for missing templates, error when 'system' not found as user. (#3998) --- .../services/store/mattermostauthlayer/mattermostauthlayer.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/server/services/store/mattermostauthlayer/mattermostauthlayer.go b/server/services/store/mattermostauthlayer/mattermostauthlayer.go index c0a1b4ca8..07c88c8e5 100644 --- a/server/services/store/mattermostauthlayer/mattermostauthlayer.go +++ b/server/services/store/mattermostauthlayer/mattermostauthlayer.go @@ -803,6 +803,9 @@ func (s *MattermostAuthLayer) GetMemberForBoard(boardID, userID string) (*model. bm, err := s.Store.GetMemberForBoard(boardID, userID) // Explicit membership not found if model.IsErrNotFound(err) { + if userID == model.SystemUserID { + return nil, model.NewErrNotFound(userID) + } var user *model.User // No synthetic memberships for guests user, err = s.GetUserByID(userID)