Skip to content

Commit

Permalink
Bumping latest_supported value of JwtTokenVersion to 1.2.0
Browse files Browse the repository at this point in the history
changing version number and variable name based on feedback
  • Loading branch information
christopappas committed Mar 18, 2019
1 parent b46d20a commit 2b31afb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion edx_rest_framework_extensions/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
""" edx Django REST Framework extensions. """

__version__ = '2.0.3' # pragma: no cover
__version__ = '2.1.0' # pragma: no cover
4 changes: 2 additions & 2 deletions edx_rest_framework_extensions/auth/jwt/decoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@


class JwtTokenVersion(object):
latest_supported = '1.1.0'
default_latest_supported = '1.2.0'

starting_version = '1.0.0'
added_version = '1.1.0'
Expand Down Expand Up @@ -89,7 +89,7 @@ def _set_token_defaults(token):
"""
def _verify_version(jwt_version):
supported_version = Version(
settings.JWT_AUTH.get('JWT_SUPPORTED_VERSION', JwtTokenVersion.latest_supported)
settings.JWT_AUTH.get('JWT_SUPPORTED_VERSION', JwtTokenVersion.default_latest_supported)
)
if jwt_version.major > supported_version.major:
logger.info('Token decode failed due to unsupported JWT version number [%s]', str(jwt_version))
Expand Down

0 comments on commit 2b31afb

Please sign in to comment.