Pārlūkot izejas kodu

quant 币对比对不区分大小写

JiahengHe 2 gadi atpakaļ
vecāks
revīzija
c3ec0d6cd5
1 mainītis faili ar 1 papildinājumiem un 3 dzēšanām
  1. 1 3
      strategy/src/quant.rs

+ 1 - 3
strategy/src/quant.rs

@@ -968,9 +968,7 @@ impl Quant {
         match self.platform_rest.get_positions().await {
             Ok(val)=>{
                 for position in val {
-                    info!("清仓-仓位信息:{:?}", position);
-                    info!("现行币对:{}", self.symbol);
-                    if position.symbol != self.symbol{
+                    if !position.symbol.eq_ignore_ascii_case(self.symbol.as_str()){
                         continue;
                     }
                     match self.platform_rest.get_ticker().await {