0
0
Fork 1
mirror of https://mau.dev/maunium/synapse.git synced 2024-11-16 23:11:34 +01:00

Use efficient .intersection

This commit is contained in:
Erik Johnston 2018-07-17 11:07:04 +01:00
parent 850238b4ef
commit b2aa05a8d6

View file

@ -80,10 +80,7 @@ class StreamChangeCache(object):
) )
} }
result = { result = changed_entities.intersection(entities)
e for e in entities
if e in changed_entities
}
self.metrics.inc_hits() self.metrics.inc_hits()
else: else: