Fixed datatype issue when creating a new languages profile with PostgreSQL.

This commit is contained in:
morpheus65535 2023-10-15 16:13:27 -04:00
parent c89da3e619
commit 2a8a4030b9

View file

@ -70,7 +70,7 @@ class SystemSettings(Resource):
items=json.dumps(item['items']),
mustContain=str(item['mustContain']),
mustNotContain=str(item['mustNotContain']),
originalFormat=item['originalFormat'] if item['originalFormat'] != 'null' else None,
originalFormat=int(item['originalFormat']) if item['originalFormat'] != 'null' else None,
)
.where(TableLanguagesProfiles.profileId == item['profileId']))
existing.remove(item['profileId'])
@ -85,7 +85,7 @@ class SystemSettings(Resource):
items=json.dumps(item['items']),
mustContain=str(item['mustContain']),
mustNotContain=str(item['mustNotContain']),
originalFormat=item['originalFormat'] if item['originalFormat'] != 'null' else None,
originalFormat=int(item['originalFormat']) if item['originalFormat'] != 'null' else None,
))
for profileId in existing:
# Remove deleted profiles