From ccdd3d0c000c069ba148326be6b7d64e32917aa9 Mon Sep 17 00:00:00 2001 From: Kevin Liu Date: Sun, 30 Oct 2016 08:46:53 -0700 Subject: [PATCH] Return instead of panic on writeln --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index cf5a0f9..da621f8 100644 --- a/src/main.rs +++ b/src/main.rs @@ -415,7 +415,7 @@ fn delete_lines_from_record>(record: R, graves: &[String]) }; let mut f = fs::File::create(record)?; for line in lines_to_write { - writeln!(f, "{}", line).unwrap(); + writeln!(f, "{}", line)?; } Ok(())