PERF: using comparison operation instead of tolerant_equals

This commit is contained in:
fawce
2013-11-12 22:40:53 -05:00
committed by Eddie Hebert
parent 923d3e4cbc
commit 395ce67c53
+4 -4
View File
@@ -191,12 +191,12 @@ class Blotter(object):
if trade_event.type != zp.DATASOURCE_TYPE.TRADE:
return
if zp_math.tolerant_equals(trade_event.volume, 0):
# there are zero volume trade_events bc some stocks trade
# less frequently than once per minute.
if trade_event.sid not in self.open_orders:
return
if trade_event.sid not in self.open_orders:
if trade_event.volume < 1:
# there are zero volume trade_events bc some stocks trade
# less frequently than once per minute.
return
orders = self.open_orders[trade_event.sid]