Django 1.6 login fix (#522)
This commit is contained in:
		| @@ -4,6 +4,7 @@ Changelog | |||||||
|  |  | ||||||
| Changes in 0.8.5 | Changes in 0.8.5 | ||||||
| ================ | ================ | ||||||
|  | - Django 1.6 login fix (#522) | ||||||
| - Django 1.6 session fix (#509) | - Django 1.6 session fix (#509) | ||||||
| - EmbeddedDocument._instance is now set when settng the attribute (#506) | - EmbeddedDocument._instance is now set when settng the attribute (#506) | ||||||
| - Fixed EmbeddedDocument with ReferenceField equality issue (#502) | - Fixed EmbeddedDocument with ReferenceField equality issue (#502) | ||||||
|   | |||||||
| @@ -1,4 +1,5 @@ | |||||||
| from django.conf import settings | from django.conf import settings | ||||||
|  | from django.contrib.auth.hashers import make_password | ||||||
| from django.contrib.auth.models import UserManager | from django.contrib.auth.models import UserManager | ||||||
| from django.core.exceptions import ImproperlyConfigured | from django.core.exceptions import ImproperlyConfigured | ||||||
| from django.db import models | from django.db import models | ||||||
| @@ -108,3 +109,7 @@ class MongoUser(models.Model): | |||||||
|  |  | ||||||
|     class Meta: |     class Meta: | ||||||
|         app_label = 'mongo_auth' |         app_label = 'mongo_auth' | ||||||
|  |  | ||||||
|  |     def set_password(self, password): | ||||||
|  |         """Doesn't do anything, but works around the issue with Django 1.6.""" | ||||||
|  |         make_password(password) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user