Merge branch 'release/0.9.6'

This commit is contained in:
Tyson Clugg 2015-07-07 14:36:49 +10:00
commit 7481a16fe7
4 changed files with 12 additions and 4 deletions

View file

@ -1,6 +1,11 @@
Change Log
==========
0.9.6
-----
* Correct method signature to match Meteor Accounts.resetPassword in
dddp.accounts submodule.
0.9.5
-----
* Include array of `permissions` on User publication.

View file

@ -170,6 +170,9 @@ Contributors
`Tyson Clugg <https://github.com/tysonclugg>`_
* Author, conceptual design.
`Yan Le <https://github.com/janusle>`_
* Validate and bug fix dddp.accounts submodule.
`MEERQAT <http://meerqat.com.au/>`_
* Project sponsor - many thanks for allowing this to be released under an open source license!

View file

@ -442,10 +442,10 @@ class Auth(APIMixin):
)
@api_endpoint('resetPassword')
def reset_password(self, params):
def reset_password(self, token, new_password):
"""Reset password using a token received in email then logs user in."""
user, _ = self.validated_user_and_session(params['token'])
user.set_password(params['newPassword'])
user, _ = self.validated_user_and_session(token)
user.set_password(new_password)
user.save()
auth.login(this.request, user)
self.update_subs(user.pk)

View file

@ -5,7 +5,7 @@ from setuptools import setup, find_packages
setup(
name='django-ddp',
version='0.9.5',
version='0.9.6',
description=__doc__,
long_description=open('README.rst').read(),
author='Tyson Clugg',