fix: remove appcontext which is removed in flask
This commit is contained in:
parent
387139f945
commit
b27fdc7293
1 changed files with 1 additions and 9 deletions
|
@ -5,14 +5,6 @@ flask_cas.__init__
|
||||||
import flask
|
import flask
|
||||||
from flask import current_app
|
from flask import current_app
|
||||||
|
|
||||||
# Find the stack on which we want to store the database connection.
|
|
||||||
# Starting with Flask 0.9, the _app_ctx_stack is the correct one,
|
|
||||||
# before that we need to use the _request_ctx_stack.
|
|
||||||
try:
|
|
||||||
from flask import _app_ctx_stack as stack
|
|
||||||
except ImportError:
|
|
||||||
from flask import _request_ctx_stack as stack
|
|
||||||
|
|
||||||
from . import routing
|
from . import routing
|
||||||
|
|
||||||
from functools import wraps
|
from functools import wraps
|
||||||
|
@ -65,7 +57,7 @@ class CAS(object):
|
||||||
app.teardown_request(self.teardown)
|
app.teardown_request(self.teardown)
|
||||||
|
|
||||||
def teardown(self, exception):
|
def teardown(self, exception):
|
||||||
ctx = stack.top
|
pass
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def app(self):
|
def app(self):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue