From b452d63fa6b2fbf7d4f74976ee12cf60d7a09f4c Mon Sep 17 00:00:00 2001 From: Steven Date: Mon, 18 Sep 2023 22:41:49 +0800 Subject: [PATCH] chore: skip compose memo error --- api/v1/memo.go | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/api/v1/memo.go b/api/v1/memo.go index fcfd5992..f72a8b27 100644 --- a/api/v1/memo.go +++ b/api/v1/memo.go @@ -797,7 +797,6 @@ func (s *APIV1Service) convertMemoFromStore(ctx context.Context, memo *store.Mem } else { memoResponse.CreatorName = user.Username } - memoResponse.CreatorUsername = user.Username // Compose display ts. @@ -822,10 +821,7 @@ func (s *APIV1Service) convertMemoFromStore(ctx context.Context, memo *store.Mem resource, err := s.Store.GetResource(ctx, &store.FindResource{ ID: &resourceID, }) - if err != nil { - return nil, err - } - if resource != nil { + if resource != nil && err == nil { resourceList = append(resourceList, convertResourceFromStore(resource)) } }