diff --git a/api/account.go b/api/account.go index 17de652..6f8410b 100644 --- a/api/account.go +++ b/api/account.go @@ -74,7 +74,7 @@ func (server *Server) getAccount(ctx *gin.Context) { return } - ctx.JSON(http.StatusBadRequest, errorResponse(err)) + ctx.JSON(http.StatusInternalServerError, errorResponse(err)) return } @@ -101,7 +101,7 @@ func (server *Server) listAccounts(ctx *gin.Context) { accounts, err := server.store.ListAccounts(ctx, arg) if err != nil { - ctx.JSON(http.StatusBadRequest, errorResponse(err)) + ctx.JSON(http.StatusInternalServerError, errorResponse(err)) return }