diff --git a/internal/utils/response_handler.go b/internal/utils/response_handler.go index 5dd7f33..e33dcce 100644 --- a/internal/utils/response_handler.go +++ b/internal/utils/response_handler.go @@ -39,12 +39,12 @@ func HandleValidationError(c *gin.Context, err error) { func HandleUserUpdateError(c *gin.Context, err error) { switch err { case errors.ErrUserNotFound: - RespondWithError(c, err, "Error while updating user", http.StatusNotFound, "user", "server.validation.user_not_found") + RespondWithError(c, err, "Error while updating user", http.StatusNotFound, "user.user", "server.validation.user_not_found") case errors.ErrInvalidUserData: - RespondWithError(c, err, "Error while updating user", http.StatusBadRequest, "user", "server.validation.invalid_user_data") + RespondWithError(c, err, "Error while updating user", http.StatusBadRequest, "user.user", "server.validation.invalid_user_data") case errors.ErrSubscriptionNotFound: RespondWithError(c, err, "Error while updating user", http.StatusBadRequest, "subscription", "server.validation.subscription_data") default: - RespondWithError(c, err, "Error while updating user", http.StatusInternalServerError, "user", "server.error.internal_server_error") + RespondWithError(c, err, "Error while updating user", http.StatusInternalServerError, "user.user", "server.error.internal_server_error") } }