Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change request.DATA to request.data for #1 #3

Merged
merged 2 commits into from
Sep 17, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ matrix:
fast_finish: true

install:
- pip install Django==$DJANGO_VERSION djangorestframework==3.1.1
- pip install Django==$DJANGO_VERSION djangorestframework==3.2.3
- pip install coveralls
script:
coverage run runtests.py
Expand Down
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,3 +89,10 @@ The `obtain_expiring_auth_token` view works exactly the same as the `obtain_auth
* Variable token lifespans.
* Possibly change `obtain_expiring_auth_token` to always replace an existing token. (Configurable?)
* South Migrations

## Changelog

* 0.1.2
* Changed from deprecated `request.DATA` to `request.data`
* 0.1.1
* Initial release
2 changes: 1 addition & 1 deletion rest_framework_expiring_authtoken/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
'views'
]

__version__ = '0.1.1'
__version__ = '0.1.2'
2 changes: 1 addition & 1 deletion rest_framework_expiring_authtoken/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class ObtainExpiringAuthToken(ObtainAuthToken):

def post(self, request):
"""Respond to POSTed username/password with token."""
serializer = AuthTokenSerializer(data=request.DATA)
serializer = AuthTokenSerializer(data=request.data)

if serializer.is_valid():
token, _ = ExpiringToken.objects.get_or_create(
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
license='BSD',
packages=find_packages(exclude=['tests*']),
install_requires=[
'djangorestframework>=3.1.1'
'djangorestframework>=3.2.3'
],
test_suite='runtests.run',
tests_require=['Django'],
Expand Down