Skip to content

Commit

Permalink
Update fields.py
Browse files Browse the repository at this point in the history
When setting JSONFIELD_CUSTOM the logic was importing under the wrong name with `Base` suffix raising `Import Error` as the module ended up having no `JSONField` to be imported.

Looks like due toa  recent change the JSONFieldBase` is no more needed.
  • Loading branch information
rochacbruno authored and nijel committed Sep 6, 2023
1 parent 4b4b019 commit 3798bc1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion social_django/fields.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
from django.utils.module_loading import import_string
except ImportError:
from importlib import import_module as import_string
JSONFieldBase = import_string(JSONFIELD_CUSTOM)
JSONField = import_string(JSONFIELD_CUSTOM)
else:
try:
from django.db.models import JSONField
Expand Down

0 comments on commit 3798bc1

Please sign in to comment.