This commit is contained in:
AB
2020-12-06 13:38:17 +03:00
parent b2bb016573
commit 417a50a2dd
2 changed files with 10 additions and 10 deletions

View File

@ -67,7 +67,7 @@ pub(crate) async fn get_files(
let file_hash = hasher.digest().to_string();
match db::get_file(file_hash.clone()).await {
Ok(_) => {
println!("File exist");
info!("File {} exist", file_hash);
}
Err(_) => {
let mut dest = File::create(path.clone())?;
@ -76,7 +76,7 @@ pub(crate) async fn get_files(
};
db::add_file(&message, path, file_hash).await?;
}
Err(e) => println!("Couldn't get file: {}", e)
Err(e) => warn!("Couldn't get file: {}", e)
}
}
};