mirror of
https://github.com/chatmail/core.git
synced 2026-04-28 10:56:29 +03:00
Fix tokio panic
This might not be needed after all because of https://github.com/tokio-rs/tokio/pull/5710, but since I already wrote the code, I created a PR anyway.
This commit is contained in:
@@ -6,6 +6,7 @@ use anyhow::{anyhow, bail, ensure, Context, Result};
|
||||
pub use deltachat::accounts::Accounts;
|
||||
use deltachat::message::get_msg_read_receipts;
|
||||
use deltachat::qr::Qr;
|
||||
use deltachat::tools;
|
||||
use deltachat::{
|
||||
chat::{
|
||||
self, add_contact_to_chat, forward_msgs, get_chat_media, get_chat_msgs, get_chat_msgs_ex,
|
||||
@@ -152,7 +153,7 @@ impl CommandApi {
|
||||
impl CommandApi {
|
||||
/// Test function.
|
||||
async fn sleep(&self, delay: f64) {
|
||||
tokio::time::sleep(std::time::Duration::from_secs_f64(delay)).await
|
||||
tools::sleep(std::time::Duration::from_secs_f64(delay)).await
|
||||
}
|
||||
|
||||
// ---------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user