Fix for #2209 - Flip the None check to happen first instead of second, otherwise if Notes is None then the first check will fail due to trying to len(None)

This commit is contained in:
blitzmann
2020-06-26 23:30:15 -04:00
parent 31cae0e54b
commit b3e5763cfc

View File

@@ -72,7 +72,7 @@ def exportESI(ofit, exportCharges, callback):
# 2017/03/29 NOTE: "<" or "&lt;" is Ignored
# fit['description'] = "<pyfa:%d />" % ofit.ID
fit['description'] = ofit.notes[:397] + '...' if len(ofit.notes) > 400 else ofit.notes if ofit.notes is not None else ""
fit['description'] = "" if ofit.notes is None else ofit.notes[:397] + '...' if len(ofit.notes) > 400 else ofit.notes
fit['items'] = []
slotNum = {}