You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In RestController we catch/wrap Grails GORM ValidationExceptions in our own Hoist version of the same - the Hoist class processes the message into something that's actually readable.
Nice catch -- we actually do this in ExceptionHandler already, just need to use it.
Generally, when we handle an exception and don't rethrow on the server, we want to use handleException(). It handles sanitization, and the special handling of RoutineExceptions, among other things.
In
RestController
we catch/wrap Grails GORM ValidationExceptions in our own Hoist version of the same - the Hoist class processes the message into something that's actually readable.https://github.com/xh/hoist-core/blob/develop/grails-app/controllers/io/xh/hoist/RestController.groovy#L76
Any reason not to always do this within
ExceptionHandler
so it is the default serialization for that class of exceptions?The text was updated successfully, but these errors were encountered: