old_state_events should be a dict not list

This commit is contained in:
Erik Johnston 2014-10-31 10:47:04 +00:00
parent 841df4da71
commit d84f5b30b8

View File

@ -138,8 +138,10 @@ class StateHandler(object):
if old_state: if old_state:
event.state_group = None event.state_group = None
event.old_state_events = old_state event.old_state_events = {
event.state_events = {(s.type, s.state_key): s for s in old_state} (s.type, s.state_key): s for s in old_state
}
event.state_events = event.old_state_events
if hasattr(event, "state_key"): if hasattr(event, "state_key"):
event.state_events[(event.type, event.state_key)] = event event.state_events[(event.type, event.state_key)] = event