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
Currently we manually create an errorResponse object in the ExceptionMapper. This pattern worked when we were dealing with effectively random errors that could be thrown in any way. Now that we've converted to ensuring all errors are custom thrown ones, we should be able to generalize this to instead make use of a custom function. By adding a function to the base custom error, and letting all sub-errors inherit this method, all errors can be converted to an ErrorResponse in a clean manner.
The text was updated successfully, but these errors were encountered:
Related to #149
Currently we manually create an errorResponse object in the ExceptionMapper. This pattern worked when we were dealing with effectively random errors that could be thrown in any way. Now that we've converted to ensuring all errors are custom thrown ones, we should be able to generalize this to instead make use of a custom function. By adding a function to the base custom error, and letting all sub-errors inherit this method, all errors can be converted to an ErrorResponse in a clean manner.
The text was updated successfully, but these errors were encountered: