Open pastly opened 7 years ago
Can you please explain more of what you meant when you created this issue?
We abort(404)
a lot, where 404 is some HTTP status code. This produces those ugly white error pages.
Instead of aborting, I suggest an error module, errors.py
or an error page template. Spit balling ideas here:
example pseudo code
def people.show(id):
if not can_show(session, id):
title = "Permission denied"
errors = ["You do not have permission to see that person"]
code = 403
return redirect(url_for('error', title=title, errors=errors), code=code)
This example uses the template idea.
And use it instead of aborting so much.