mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 14:52:15 +00:00
Check by ID not the newly created db object
This commit is contained in:
@@ -142,7 +142,7 @@ def import_eve_character_func(character_id, api_key=None, user_id=None, logger=l
|
||||
|
||||
try:
|
||||
acc = EVEAccount.objects.get(api_user_id=user_id)
|
||||
if not pchar in acc.characters.all():
|
||||
if not pchar.id in acc.characters.all().values_list('id', flat=True):
|
||||
acc.characters.add(pchar)
|
||||
|
||||
if pchar.director and acc.api_keytype == API_KEYTYPE_FULL:
|
||||
|
||||
Reference in New Issue
Block a user