Fix time comparison
This commit is contained in:
parent
9c5a3f0a93
commit
143e06b1b1
|
|
@ -72,7 +72,7 @@ pub async fn list_up_for_buy(
|
||||||
supertrend_1m_map.get(symbol),
|
supertrend_1m_map.get(symbol),
|
||||||
price_and_closetime,
|
price_and_closetime,
|
||||||
) {
|
) {
|
||||||
if supertrend_vec.last().unwrap().close_time > current_info.1
|
if supertrend_vec.last().unwrap().close_time > server_epoch
|
||||||
&& supertrend_vec.last().unwrap().signal.as_ref().is_some_and(|a| *a == SuperTrendSignal::BUY)
|
&& supertrend_vec.last().unwrap().signal.as_ref().is_some_and(|a| *a == SuperTrendSignal::BUY)
|
||||||
{
|
{
|
||||||
values.current_price = current_info.0;
|
values.current_price = current_info.0;
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,7 @@ pub async fn list_up_for_buy(
|
||||||
supertrend_1m_map.get(symbol),
|
supertrend_1m_map.get(symbol),
|
||||||
price_and_closetime,
|
price_and_closetime,
|
||||||
) {
|
) {
|
||||||
if supertrend_vec.last().unwrap().close_time > current_info.1
|
if supertrend_vec.last().unwrap().close_time > server_epoch
|
||||||
&& supertrend_vec.last().unwrap().signal.as_ref().is_some_and(|a| *a == SuperTrendSignal::SELL)
|
&& supertrend_vec.last().unwrap().signal.as_ref().is_some_and(|a| *a == SuperTrendSignal::SELL)
|
||||||
{
|
{
|
||||||
values.current_price = current_info.0;
|
values.current_price = current_info.0;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user