Do not allow import of unpublished items (temporary measure to prevent abyssal items)

This commit is contained in:
blitzmann
2018-05-29 21:01:55 -04:00
parent ba2471e75c
commit b097818f1b

View File

@@ -483,6 +483,8 @@ class Port(object):
for module in items:
try:
item = sMkt.getItem(module['type_id'], eager="group.category")
if not item.published:
continue
if module['flag'] == INV_FLAG_DRONEBAY:
d = Drone(item)
d.amount = module['quantity']
@@ -679,6 +681,9 @@ class Port(object):
pyfalog.warning("no data can be found (old names)")
continue
if not item.published:
continue
if item.category.name == "Drone":
extraAmount = int(extraAmount) if extraAmount is not None else 1
if modName not in droneMap:
@@ -992,7 +997,7 @@ class Port(object):
for hardware in hardwares:
try:
item = _resolve_module(hardware, sMkt, b_localized)
if not item:
if not item or not item.published:
continue
if item.category.name == "Drone":