chore: release v0.4.3

This commit is contained in:
Steven
2022-09-09 20:00:04 +08:00
parent d1a4348048
commit b8a7df21f2
6 changed files with 16 additions and 9 deletions

View File

@ -24,7 +24,7 @@ func (s *Server) registerAuthRoutes(g *echo.Group) {
Email: &signin.Email,
}
user, err := s.Store.FindUser(ctx, userFind)
if err != nil {
if err != nil && common.ErrorCode(err) != common.NotFound {
return echo.NewHTTPError(http.StatusInternalServerError, fmt.Sprintf("Failed to find user by email %s", signin.Email)).SetInternal(err)
}
if user == nil {
@ -68,7 +68,7 @@ func (s *Server) registerAuthRoutes(g *echo.Group) {
Role: &hostUserType,
}
hostUser, err := s.Store.FindUser(ctx, &hostUserFind)
if err != nil {
if err != nil && common.ErrorCode(err) != common.NotFound {
return echo.NewHTTPError(http.StatusInternalServerError, "Failed to find host user").SetInternal(err)
}
if hostUser != nil {