Skip to content

armgit / memos

Public Imported from GitHub
0

Memos is an open-source, self-hosted note-taking app that brings your everyday thoughts together in a personal timeline. Your data stays yours, and you choose what to keep private or share.

fix: can't change memo UID (#3621)

Roman Lomonosovb923988fd6d9
diff --git a/server/router/api/v1/memo_service.go b/server/router/api/v1/memo_service.go
index 5b62b9342..05e5f2184 100644
--- a/server/router/api/v1/memo_service.go
+++ b/server/router/api/v1/memo_service.go
@@ -254,7 +254,7 @@ func (s *APIV1Service) UpdateMemo(ctx context.Context, request *v1pb.UpdateMemoR
payload.Property = property
update.Payload = payload
} else if path == "uid" {
- update.UID = &request.Memo.Name
+ update.UID = &request.Memo.Uid
if !util.UIDMatcher.MatchString(*update.UID) {
return nil, status.Errorf(codes.InvalidArgument, "invalid resource name")
}