mirror of
https://github.com/ansible/awx.git
synced 2026-05-24 09:07:45 -02:30
Fix configure Tower in Tower to work with updated django-jsonfield.
This commit is contained in:
@@ -3,7 +3,6 @@
|
||||
|
||||
# Python
|
||||
import collections
|
||||
import json
|
||||
import sys
|
||||
|
||||
# Django
|
||||
@@ -100,9 +99,6 @@ class SettingSingletonDetail(RetrieveUpdateDestroyAPIView):
|
||||
if key == 'LICENSE':
|
||||
continue
|
||||
setattr(serializer.instance, key, value)
|
||||
# Always encode "raw" strings as JSON.
|
||||
if isinstance(value, basestring):
|
||||
value = json.dumps(value)
|
||||
setting = settings_qs.filter(key=key).order_by('pk').first()
|
||||
if not setting:
|
||||
setting = Setting.objects.create(key=key, user=user, value=value)
|
||||
|
||||
Reference in New Issue
Block a user