mirror of
https://github.com/chatmail/core.git
synced 2026-04-27 18:36:30 +03:00
update callback to take collection by ref
This commit is contained in:
@@ -31,7 +31,6 @@ use crate::qr::Qr;
|
||||
use anyhow::{anyhow, bail, ensure, format_err, Context as _, Result};
|
||||
use async_channel::Receiver;
|
||||
use futures_lite::StreamExt;
|
||||
use sendme::blobs::Collection;
|
||||
use sendme::get::{DataStream, Options};
|
||||
use sendme::protocol::AuthToken;
|
||||
use sendme::provider::{DataSource, Event, Provider, Ticket};
|
||||
@@ -251,7 +250,7 @@ pub async fn get_backup(context: &Context, qr: Qr) -> Result<()> {
|
||||
ticket.token,
|
||||
opts,
|
||||
on_connected,
|
||||
on_collection,
|
||||
|_collection| async { Ok(()) },
|
||||
on_blob,
|
||||
)
|
||||
.await
|
||||
@@ -280,12 +279,6 @@ async fn on_connected() -> Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Get callback when a collection is received from the provider.
|
||||
#[allow(clippy::unused_async)]
|
||||
async fn on_collection(_collection: Collection) -> Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
/// Get callback when a blob is received from the provider.
|
||||
async fn on_blob(
|
||||
context: &Context,
|
||||
|
||||
Reference in New Issue
Block a user