fix: return key bug:

pull/23/head
db0 2023-09-14 10:42:44 +02:00
parent f9508447af
commit 9574b9b36b
1 changed files with 1 additions and 1 deletions

View File

@ -189,7 +189,7 @@ class WhitelistDomain(Resource):
changed = True changed = True
db.session.commit() db.session.commit()
if changed is True: if changed is True:
if self.args.return_new_key and new_key is True: if self.args.return_new_key and new_key is not None:
return {"message": "Changed", "new_key": new_key},200 return {"message": "Changed", "new_key": new_key},200
else: else:
return {"message": "Changed"},200 return {"message": "Changed"},200