π The open-source, offline-first Notion, Obsidian & Confluence alternative. Advanced Markdown, multi-tenant teams, OIDC/SSO, and local S3 backups. Deploy in one command.
Vue dockergolangkanbanknowledge-baseknowledge-managementmarkdownnote-takingnotesnotes-appnotionnuxtnuxtjsoffline-firstoidcpwaselfhostedssovuevuejswiki
Fix error message bad return type
Smaug6739d0dd88b5deac
diff --git a/backend/controllers/categories.controller.go b/backend/controllers/categories.controller.goindex cd27556c..40b71526 100644--- a/backend/controllers/categories.controller.go+++ b/backend/controllers/categories.controller.go@@ -4,6 +4,7 @@ import ("alexandrie/app""alexandrie/models""alexandrie/utils"+ "errors""net/http""github.com/gin-gonic/gin"@@ -54,7 +55,7 @@ func (ctr *Controller) GetCategories(c *gin.Context) (int, any) {func (ctr *Controller) CreateCategory(c *gin.Context) (int, any) {var category models.Categoryif err := c.ShouldBind(&category); err != nil {- return http.StatusBadRequest, utils.Error("Invalid request payload")+ return http.StatusBadRequest, errors.New("invalid request payload")}userId, err := utils.GetUserIdCtx(c)