Allow 'inversematch' on last fix

This commit is contained in:
Ruben van de Ven 2019-08-26 08:12:22 +02:00
parent e819e599db
commit 2cd47470de

View file

@ -467,10 +467,12 @@ class Condition(object):
msg = story.get(self.vars['msgId'])
if not msg:
story.logger.critical(f"Condition on non-existing message: {self.vars['msgId']}")
return False
# assigning false to r, keeps 'inverseMatch' working, even when msgId is wrong
r = False
else:
#: :type msg: Message
r = msg.isFinished()
#: :type msg: Message
r = msg.isFinished()
if r:
story.logger.debug(f"Msg {self.vars['msgId']} has been played.")