From: Matías Aguirre Date: Thu, 31 Mar 2011 20:54:36 +0000 (-0300) Subject: Use get_prep_value instead of the database related one. Closes gh-42 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=edd2cc66fff3159699c28c8f86c52e6524ce9d86;p=django-social-auth.git Use get_prep_value instead of the database related one. Closes gh-42 --- diff --git a/social_auth/fields.py b/social_auth/fields.py index 4664155..46a5f25 100644 --- a/social_auth/fields.py +++ b/social_auth/fields.py @@ -34,7 +34,7 @@ class JSONField(models.TextField): except Exception, e: raise ValidationError(str(e)) - def get_db_prep_value(self, value, connection, prepared=False): + def get_prep_value(self, value): """Convert value to JSON string before save""" try: return simplejson.dumps(value)