fix: use argument timeframe instead of self.

This commit is contained in:
Joe Schr 2021-09-01 10:31:31 +02:00
parent a05277a4d0
commit 89599b09c3

View File

@ -125,7 +125,7 @@ def find_candle_datetime_faster(dataframe: pd.DataFrame, timeframe: str, query_d
if(now and now == query_date):
candle = dataframe.iloc[-1]
else:
candle_date = timeframe_to_prev_date(self.timeframe, query_date)
candle_date = timeframe_to_prev_date(timeframe, query_date)
candle = dataframe.loc[dataframe.date == candle_date]
return candle