app_async: don't use writer.sink()

This commit is contained in:
Dmitry Belyaev 2023-08-15 10:44:32 +03:00
parent 07d7ba50cc
commit 0adc11cabf
Signed by: b4tman
GPG Key ID: 41A00BF15EA7E5F3

View File

@ -181,8 +181,8 @@ async fn db_writer_task(rx: UnboundedReceiver<Question>) {
.unwrap_or_else(|e| panic!("db writer load, {e:#?}"));
let stream: UnboundedReceiverStream<_> = rx.into();
let stream = stream.map(Ok);
stream.forward(writer.sink()).await.expect("forward");
let stream = stream;
writer.load(stream).await.expect("load");
writer.finish().await.expect("db writer finish");
println!("write done");