flask_boost/project/application/__init__.py
def register_error_handle(app):
    """Register HTTP error pages."""

    @app.errorhandler(403)
    def page_403(error):
        return render_template('site/403/403.html'), 403

    @app.errorhandler(404)
    def page_404(error):
        return render_template('site/404/404.html'), 404

    @app.errorhandler(500)
    def page_500(error):
        return render_template('site/500/500.html'), 500
def register_error_handle(app):
    @app.errorhandler(403)
    def page_403(error):
        return render_template('site/403/403.html'), 403

    @app.errorhandler(404)
    def page_404(error):
        return render_template('site/404/404.html'), 404

    @app.errorhandler(500)
    def page_500(error):
        return render_template('site/500/500.html'), 500
def register_error_handle ( app ) : @ app . errorhandler ( 403 ) def page_403 ( error ) : return render_template ( 'site/403/403.html' ) , 403 @ app . errorhandler ( 404 ) def page_404 ( error ) : return render_template ( 'site/404/404.html' ) , 404 @ app . errorhandler ( 500 ) def page_500 ( error ) : return render_template ( 'site/500/500.html' ) , 500
Register HTTP error pages.
Register HTTP error pages .