Directly return werkzeug responses to flask
This fixes redirects to the login page when not logged in.