some stuff from mac

This commit is contained in:
Dmitry Chumak
2025-06-12 13:12:20 +03:00
parent 5ed47a796f
commit b653bdc1b6
10 changed files with 551 additions and 60 deletions

View File

@@ -1,6 +1,7 @@
package user
import (
"fmt"
"net/http"
"time"
@@ -91,7 +92,7 @@ func (h *AuthHandler) Register(c *gin.Context) {
Password: string(hashedPassword),
})
if err != nil {
c.JSON(http.StatusInternalServerError, gin.H{"error": "failed to create user"})
c.JSON(http.StatusInternalServerError, gin.H{"error": fmt.Sprintf("failed to create user with err: '%v'", err)})
return
}