Skip to content

Commit eec701d

Browse files
committed
added docstring for rotate_refresh_token, removed unused import, chagelog modified
1 parent 5c2c6a2 commit eec701d

File tree

5 files changed

+4
-1
lines changed

5 files changed

+4
-1
lines changed

AUTHORS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,4 @@ Jim Graham
2222
pySilver
2323
Silvano Cerza
2424
Federico Dolce
25+
Alessandro De Angelis

docs/changelog.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ Changelog
44
Development
55
~~~~~~~~~~~
66

7+
* #424: Added a ROTATE_REFRESH_TOKEN setting to control whether refresh tokens are reused or not
78
* #315: AuthorizationView does not overwrite requests on get
89
* #425: Added support for Django 1.10
910
* #396: Added an IsAuthenticatedOrTokenHasScope Permission

oauth2_provider/oauth2_validators.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -299,6 +299,7 @@ def save_authorization_code(self, client_id, code, request, *args, **kwargs):
299299

300300
def rotate_refresh_token(self, request):
301301
"""
302+
Checks if rotate refresh token is enabled
302303
"""
303304
return oauth2_settings.ROTATE_REFRESH_TOKEN
304305

oauth2_provider/settings.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,4 +155,5 @@ def validate_setting(self, attr, val):
155155
if not val and attr in self.mandatory:
156156
raise AttributeError("OAuth2Provider setting: '%s' is mandatory" % attr)
157157

158+
158159
oauth2_settings = OAuth2ProviderSettings(USER_SETTINGS, DEFAULTS, IMPORT_STRINGS, MANDATORY)

oauth2_provider/tests/test_authorization_code.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
import base64
44
import json
55
import datetime
6-
import mock
76

87
from django.contrib.auth import get_user_model
98
from django.core.urlresolvers import reverse

0 commit comments

Comments
 (0)