In case of a non-pre-defined error, raise an AppError and give access to error.data