feat: add visibility field to memo (#109)

* feat: add `visibility` field to memo

* chore: fix typo
This commit is contained in:
boojack
2022-07-08 22:23:27 +08:00
committed by GitHub
parent aed137472c
commit 697d01e306
6 changed files with 67 additions and 24 deletions

View File

@ -22,6 +22,9 @@ func (s *Server) registerMemoRoutes(g *echo.Group) {
return echo.NewHTTPError(http.StatusBadRequest, "Malformatted post memo request").SetInternal(err)
}
// TODO(steven): remove this line after frontend is ready
memoCreate.Visibility = api.Privite
memo, err := s.Store.CreateMemo(memoCreate)
if err != nil {
return echo.NewHTTPError(http.StatusInternalServerError, "Failed to create memo").SetInternal(err)