fix: get user by username api (#2034)

This commit is contained in:
boojack
2023-07-26 22:41:21 +08:00
committed by GitHub
parent 56c321aeaa
commit d8d6de9fca
10 changed files with 21 additions and 43 deletions

View File

@ -542,13 +542,6 @@ func (s *APIV1Service) registerMemoRoutes(g *echo.Group) {
findMemoMessage.Pinned = &pinned
}
if username := c.QueryParam("creatorUsername"); username != "" {
user, _ := s.Store.GetUser(ctx, &store.FindUser{Username: &username})
if user != nil {
findMemoMessage.CreatorID = &user.ID
}
}
contentSearch := []string{}
tag := c.QueryParam("tag")
if tag != "" {