1
2
Fork 0
mirror of https://github.com/mat-1/azalea.git synced 2025-08-02 14:26:04 +00:00

fix compile error in newer nightly versions

This commit is contained in:
mat 2024-04-28 17:38:21 -05:00
parent 83cce23614
commit 0c05b4cd42
2 changed files with 619 additions and 524 deletions

1126
Cargo.lock generated

File diff suppressed because it is too large Load diff

View file

@ -343,7 +343,7 @@ where
let mut swarm_clone = swarm.clone(); let mut swarm_clone = swarm.clone();
let join_delay = self.join_delay; let join_delay = self.join_delay;
let accounts = self.accounts.clone(); let accounts = self.accounts.clone();
let states = self.states.clone(); let states: Vec<S> = self.states.clone();
let join_task = tokio::spawn(async move { let join_task = tokio::spawn(async move {
if let Some(join_delay) = join_delay { if let Some(join_delay) = join_delay {
@ -357,15 +357,12 @@ where
} else { } else {
// otherwise, join all at once // otherwise, join all at once
let swarm_borrow = &swarm_clone; let swarm_borrow = &swarm_clone;
join_all(accounts.iter().zip(states).map( join_all(accounts.iter().zip(states).map(|(account, state)| async {
async move |(account, state)| -> Result<(), JoinError> { swarm_borrow
swarm_borrow .clone()
.clone() .add_with_exponential_backoff(account, state)
.add_with_exponential_backoff(account, state.clone()) .await;
.await; }))
Ok(())
},
))
.await; .await;
} }
}); });