mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2025-04-14 08:17:13 +03:00
Fix outfitting module sanity check.
This commit is contained in:
parent
f60df9af07
commit
870fedecd3
@ -320,7 +320,9 @@ def lookup(module):
|
||||
|
||||
# check we've filled out mandatory fields
|
||||
for thing in ['category', 'name', 'class', 'rating']:
|
||||
if not new.get('name'): raise AssertionError('%s: failed to set %s' % (module['id'], thing))
|
||||
if not new.get(thing): raise AssertionError('%s: failed to set %s' % (module['id'], thing))
|
||||
if new['category'] == 'hardpoint' and not new.get('mount'):
|
||||
raise AssertionError('%s: failed to set %s' % (module['id'], 'mount'))
|
||||
|
||||
return new
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user