Updated dependencies
This commit is contained in:
870
Cargo.lock
generated
870
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -49,7 +49,7 @@ sqlx = { version = "0.8", features = [
|
|||||||
"migrate",
|
"migrate",
|
||||||
] }
|
] }
|
||||||
subtle = "2"
|
subtle = "2"
|
||||||
teloxide = { version = "0.15", features = [
|
teloxide = { version = "0.17", features = [
|
||||||
"macros",
|
"macros",
|
||||||
"ctrlc_handler",
|
"ctrlc_handler",
|
||||||
"rustls",
|
"rustls",
|
||||||
@@ -62,7 +62,7 @@ tokio = { version = "1", features = [
|
|||||||
"sync",
|
"sync",
|
||||||
"parking_lot",
|
"parking_lot",
|
||||||
] }
|
] }
|
||||||
toml = "0.8"
|
toml = "0.9"
|
||||||
tracing = "0.1"
|
tracing = "0.1"
|
||||||
tracing-subscriber = { version = "0.3", features = [
|
tracing-subscriber = { version = "0.3", features = [
|
||||||
"parking_lot",
|
"parking_lot",
|
||||||
|
@@ -46,6 +46,6 @@ async fn notify_about_no_user_info(
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Gets a handler that filters out the messages without user information
|
/// Gets a handler that filters out the messages without user information
|
||||||
pub fn get_handler() -> Handler<'static, DependencyMap, crate::Result<()>, DpHandlerDescription> {
|
pub fn get_handler() -> Handler<'static, crate::Result<()>, DpHandlerDescription> {
|
||||||
dptree::filter(has_no_user_info).endpoint(notify_about_no_user_info)
|
dptree::filter(has_no_user_info).endpoint(notify_about_no_user_info)
|
||||||
}
|
}
|
||||||
|
@@ -44,6 +44,6 @@ async fn notify_about_no_master_pass(
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Gets a handler that filters out the messages of users that don't have a master password set
|
/// Gets a handler that filters out the messages of users that don't have a master password set
|
||||||
pub fn get_handler() -> Handler<'static, DependencyMap, crate::Result<()>, DpHandlerDescription> {
|
pub fn get_handler() -> Handler<'static, crate::Result<()>, DpHandlerDescription> {
|
||||||
dptree::filter_map_async(master_pass_exists).endpoint(notify_about_no_master_pass)
|
dptree::filter_map_async(master_pass_exists).endpoint(notify_about_no_master_pass)
|
||||||
}
|
}
|
||||||
|
@@ -49,7 +49,7 @@ fn validate_document(document: Option<&Document>) -> Result<&Document, InvalidDo
|
|||||||
}
|
}
|
||||||
|
|
||||||
async fn download_file(bot: &Throttle<Bot>, file: &FileMeta) -> crate::Result<Box<[u8]>> {
|
async fn download_file(bot: &Throttle<Bot>, file: &FileMeta) -> crate::Result<Box<[u8]>> {
|
||||||
let path = bot.get_file(&file.id).await?.path;
|
let path = bot.get_file(file.id.clone()).await?.path;
|
||||||
let mut data = Vec::with_capacity(file.size as usize);
|
let mut data = Vec::with_capacity(file.size as usize);
|
||||||
let mut stream = bot.download_file_stream(&path);
|
let mut stream = bot.download_file_stream(&path);
|
||||||
while let Some(bytes) = stream.try_next().await? {
|
while let Some(bytes) = stream.try_next().await? {
|
||||||
|
Reference in New Issue
Block a user