Skip to content

Commit

Permalink
Move urlsplit / urlunsplit import to compat
Browse files Browse the repository at this point in the history
  • Loading branch information
jleclanche committed Mar 15, 2017
1 parent 49d2586 commit 0be0f25
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions oauth2_provider/compat.py
Expand Up @@ -7,9 +7,9 @@

# urlparse in python3 has been renamed to urllib.parse
try:
from urlparse import urlparse, parse_qs, parse_qsl, urlunparse
from urlparse import parse_qs, parse_qsl, urlparse, urlsplit, urlunparse, urlunsplit
except ImportError:
from urllib.parse import urlparse, parse_qs, parse_qsl, urlunparse
from urllib.parse import parse_qs, parse_qsl, urlparse, urlsplit, urlunsplit, urlunparse

try:
from urllib import urlencode, quote_plus, unquote_plus
Expand Down
2 changes: 1 addition & 1 deletion oauth2_provider/validators.py
Expand Up @@ -5,9 +5,9 @@
from django.core.exceptions import ValidationError
from django.core.validators import RegexValidator
from django.utils.encoding import force_text
from django.utils.six.moves.urllib.parse import urlsplit, urlunsplit
from django.utils.translation import ugettext_lazy as _

from .compat import urlsplit, urlunsplit
from .settings import oauth2_settings


Expand Down

0 comments on commit 0be0f25

Please sign in to comment.