Skip to content

Commit

Permalink
Merge pull request #50 from Lee-W/master
Browse files Browse the repository at this point in the history
Replace wtforms.ext.sqlalchemy with wtforms_sqlalchemy if it's installed
  • Loading branch information
kvesteri committed Jul 5, 2017
2 parents 9d90385 + 8506a62 commit 5f9a78b
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions wtforms_json/__init__.py
Expand Up @@ -3,13 +3,20 @@
import six
from wtforms import Form
try:
from wtforms.ext.sqlalchemy.fields import (
from wtforms_sqlalchemy.fields import (
QuerySelectField,
QuerySelectMultipleField
)
HAS_SQLALCHEMY_SUPPORT = True
except ImportError:
HAS_SQLALCHEMY_SUPPORT = False
try:
from wtforms.ext.sqlalchemy.fields import (
QuerySelectField,
QuerySelectMultipleField
)
HAS_SQLALCHEMY_SUPPORT = True
except ImportError:
HAS_SQLALCHEMY_SUPPORT = False
from wtforms.fields import (
_unset_value,
BooleanField,
Expand Down

0 comments on commit 5f9a78b

Please sign in to comment.