Refactoring

This commit is contained in:
2026-06-06 12:29:10 -04:00
parent 422b773153
commit ce36feecfe
2 changed files with 23 additions and 45 deletions
+6 -5
View File
@@ -1,6 +1,7 @@
pub mod parser;
fn main() {
#[tokio::main]
async fn main() {
println!("clean_file");
let args: Vec<String> = std::env::args().collect();
@@ -13,10 +14,10 @@ fn main() {
println!("Filepath: {filepath:?}");
let prsr = parser::NumberParser{filepath: filepath.clone()};
match prsr.file_dump() {
Ok(numbers) => {
prsr.print_values(&numbers);
prsr.save_file(numbers);
match prsr.file_dump().await {
Ok(contacts) => {
prsr.print_phone_numbers(&contacts);
prsr.save_file(contacts).await;
}
Err(err) => {
eprintln!("Error: {err:?}");