From b097818f1ba6072e704f5b229cf1a5712e9ac181 Mon Sep 17 00:00:00 2001 From: blitzmann Date: Tue, 29 May 2018 21:01:55 -0400 Subject: [PATCH] Do not allow import of unpublished items (temporary measure to prevent abyssal items) --- service/port.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/service/port.py b/service/port.py index 37290f8f2..6ab61e6d7 100644 --- a/service/port.py +++ b/service/port.py @@ -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":