mirror of
https://github.com/hazemKrimi/crimson-vault.git
synced 2026-05-01 18:20:27 +00:00
wip: custom logger and error handler
This commit is contained in:
@@ -180,8 +180,7 @@ func (api *API) UpdateUserLogoHandler(context echo.Context) error {
|
||||
file, err := context.FormFile("logo")
|
||||
|
||||
if err != nil {
|
||||
log.Println(fmt.Sprintf("Error updating logo for User: %v.", err))
|
||||
return context.String(http.StatusBadRequest, "No image has been uploaded!")
|
||||
return types.Error{Code: http.StatusBadRequest, Messages: []string{"No image has been uploaded!"}}
|
||||
}
|
||||
|
||||
ext := strings.ToLower(filepath.Ext(file.Filename))
|
||||
|
||||
Reference in New Issue
Block a user