From 157c1148fb0b49b78325efde165722493c5359f2 Mon Sep 17 00:00:00 2001 From: willyb321 Date: Wed, 30 May 2018 07:37:20 +1000 Subject: [PATCH] Implement temporary fix for #280 --- src/app/components/ModificationsMenu.jsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/app/components/ModificationsMenu.jsx b/src/app/components/ModificationsMenu.jsx index 748d239b..fea6cd28 100644 --- a/src/app/components/ModificationsMenu.jsx +++ b/src/app/components/ModificationsMenu.jsx @@ -407,6 +407,11 @@ export default class ModificationsMenu extends TranslatedComponent { let haveBlueprint = false; let blueprintTt; let blueprintCv; + //TODO: Fix this to actually find the correct blueprint. + if (!m.blueprint || !m.blueprint.name || !m.blueprint.fdname || !Modifications.modules[m.grp].blueprints || !Modifications.modules[m.grp].blueprints[m.blueprint.fdname]) { + this.props.ship.clearModuleBlueprint(m); + this.props.ship.clearModuleSpecial(m); + } if (m.blueprint && m.blueprint.name && Modifications.modules[m.grp].blueprints[m.blueprint.fdname].grades[m.blueprint.grade]) { blueprintLabel = translate(m.blueprint.name) + ' ' + translate('grade') + ' ' + m.blueprint.grade; haveBlueprint = true;