Use AbortWithStatusJSON instead of AbortWithError
All checks were successful
continuous-integration/drone/pr Build is passing
ci/woodpecker/push/woodpecker Pipeline was successful
continuous-integration/drone/push Build is passing
ci/woodpecker/pr/woodpecker Pipeline was successful

This commit is contained in:
2022-02-20 20:42:57 +00:00
parent 36b2f12183
commit ca51ac5e27
4 changed files with 23 additions and 16 deletions

View File

@ -33,6 +33,10 @@ func (h *Handler) Serve() {
}
}
type ErrorResponse struct {
Message string
}
// LoadRoutes initializes all the routes.
func (h *Handler) LoadRoutes(router *gin.Engine) {
router.Use(enableCachingForStaticFiles())