forked from orbit-oss/flask
Support old and new name for json
This commit is contained in:
parent
aecc41deb8
commit
eb023bcfad
1 changed files with 5 additions and 2 deletions
|
|
@ -15,8 +15,11 @@ from .globals import current_app, request
|
|||
from werkzeug.http import http_date
|
||||
|
||||
# Use the same json implementation as itsdangerous on which we
|
||||
# depend anyways.
|
||||
from itsdangerous import simplejson as _json
|
||||
# depend anyways. This name changed at one point so support both.
|
||||
try:
|
||||
from itsdangerous import simplejson as _json
|
||||
except ImportError:
|
||||
from itsdangerous import json as _json
|
||||
|
||||
|
||||
# figure out if simplejson escapes slashes. This behavior was changed
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue