feat: add validation to custom claim input

This commit is contained in:
Elias Schneider
2024-10-28 18:34:25 +01:00
parent c056089c60
commit 7bfc3f43a5
4 changed files with 32 additions and 7 deletions

View File

@@ -8,7 +8,6 @@ import (
"github.com/go-playground/validator/v10"
"github.com/stonith404/pocket-id/backend/internal/common"
"gorm.io/gorm"
"log"
"net/http"
"strings"
)
@@ -54,7 +53,6 @@ func (m *ErrorHandlerMiddleware) Add() gin.HandlerFunc {
return
}
log.Println(err)
c.JSON(http.StatusInternalServerError, gin.H{"error": "Something went wrong"})
}
}