Skip to content

Commit

Permalink
ref: on_collection doesn't need to be FnMut (#136)
Browse files Browse the repository at this point in the history
It is only called once, adding FnMut is a needless restriction.

Closes #133
  • Loading branch information
flub committed Feb 13, 2023
1 parent b3ee39f commit eac7b65
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/get.rs
Original file line number Diff line number Diff line change
Expand Up @@ -119,13 +119,13 @@ pub async fn run<A, B, C, FutA, FutB, FutC>(
token: AuthToken,
opts: Options,
on_connected: A,
mut on_collection: B,
on_collection: B,
mut on_blob: C,
) -> Result<Stats>
where
A: FnOnce() -> FutA,
FutA: Future<Output = Result<()>>,
B: FnMut(&Collection) -> FutB,
B: FnOnce(&Collection) -> FutB,
FutB: Future<Output = Result<()>>,
C: FnMut(Hash, DataStream, String) -> FutC,
FutC: Future<Output = Result<DataStream>>,
Expand Down

0 comments on commit eac7b65

Please sign in to comment.