Skip to content

Commit

Permalink
style: apply fmt and lint
Browse files Browse the repository at this point in the history
  • Loading branch information
antomor committed Oct 20, 2023
1 parent 5d58d1d commit f0bb897
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions core/bin/zksync_api/src/fee_ticker/validator/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,19 +74,23 @@ impl<W: TokenWatcher> MarketUpdater<W> {
pub async fn keep_updated(mut self, duration_secs: u64) {
let mut error_counter = 0;

// Market volume is not available for these tokens and
// Market volume is not available for these tokens and
// we don't need it because they're added among the unconditionally_valid_tokens
let unavailable_market_volume_tokens = ["RDOC", "RBTC", "USDRIF"];
loop {
let tokens = self.tokens_cache.get_all_tokens().await;
let result = match tokens {
Ok(tokens) => self.update_all_tokens(
tokens
.into_iter()
.filter(|token|
!unavailable_market_volume_tokens.contains(&token.symbol.as_str())
).collect_vec(),
).await,
Ok(tokens) => {
self.update_all_tokens(
tokens
.into_iter()
.filter(|token| {
!unavailable_market_volume_tokens.contains(&token.symbol.as_str())
})
.collect_vec(),
)
.await
}
Err(e) => Err(e),
};

Expand Down

0 comments on commit f0bb897

Please sign in to comment.