Fix wrong log message

This commit is contained in:
DarkPhoenix
2019-04-20 03:59:08 +03:00
parent 051800bc16
commit 8c40489049
3 changed files with 4 additions and 4 deletions

View File

@@ -555,7 +555,7 @@ class FittingView(d.Display):
contexts = []
while sel != -1:
if sel not in self.blanks:
mod = self.mods[self.GetItemData(sel)]
# Test if this is a mode, which is a special snowflake of a Module

View File

@@ -24,7 +24,7 @@ class CalcReplaceLocalModuleCommand(wx.Command):
self.unloadedCharge = None
def Do(self):
pyfalog.debug('Doing replacement of local module at position {} to {} on fit {}'.format(self.newModInfo, self.position, self.fitID))
pyfalog.debug('Doing replacement of local module at position {} to {} on fit {}'.format(self.position, self.newModInfo, self.fitID))
self.unloadedCharge = False
sFit = Fit.getInstance()
fit = sFit.getFit(self.fitID)
@@ -63,7 +63,7 @@ class CalcReplaceLocalModuleCommand(wx.Command):
return True
def Undo(self):
pyfalog.debug('Undoing replacement of local module at position {} to {} on fit {}'.format(self.newModInfo, self.position, self.fitID))
pyfalog.debug('Undoing replacement of local module at position {} to {} on fit {}'.format(self.position, self.newModInfo, self.fitID))
sFit = Fit.getInstance()
fit = sFit.getFit(self.fitID)
# Remove if there was no module

View File

@@ -437,7 +437,7 @@ class Fit(FitDeprecated):
changedProjMods = {}
changedProjDrones = {}
for pos, mod in enumerate(fit.modules):
if mod != base:
if mod is not base:
# fix for #529, where a module may be in incorrect state after CCP changes mechanics of module
if not mod.canHaveState(mod.state) or not mod.isValidState(mod.state):
changedMods[pos] = mod.state