Skip to content
This repository was archived by the owner on Apr 28, 2020. It is now read-only.

Commit

Permalink
Switch to request_is_xhr (#381)
Browse files Browse the repository at this point in the history
  • Loading branch information
jace authored Mar 9, 2020
1 parent df83bad commit 2ab1e73
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lastuser_oauth/views/login.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
from flask_openid import OpenID
from openid import oidutil

from baseframe import _, __
from baseframe import _, __, request_is_xhr
from baseframe.forms import render_form, render_message, render_redirect
from coaster.auth import current_auth
from coaster.utils import getbool, utcnow
Expand Down Expand Up @@ -106,7 +106,7 @@ def login():
elif request.method == 'POST':
abort(500)
iframe_block = {'X-Frame-Options': 'SAMEORIGIN'}
if request.is_xhr and formid == 'passwordlogin':
if request_is_xhr() and formid == 'passwordlogin':
return (
render_template(
'loginform.html.jinja2', loginform=loginform, Markup=Markup
Expand Down

0 comments on commit 2ab1e73

Please sign in to comment.