aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2016-04-19 18:57:14 -0400
committerTeddy Wing2016-04-19 19:00:43 -0400
commita2ff502bffe10f9ba15edeab2ab81f5b4e007cc0 (patch)
tree9ee59c10578319906b81b8ddb0e6f57a8cb25709
parent7bb222bd93959ae39e8c73605f13c6413c878f3c (diff)
downloadmutt-alias-auto-add-a2ff502bffe10f9ba15edeab2ab81f5b4e007cc0.tar.bz2
is_alias_in_file_finds_a_match: Change `to_string` to `to_owned`
Saw this pattern in the Rust book chapter Error Handling (http://doc.rust-lang.org/stable/book/error-handling.html#composing-option-and-result). Not sure if this is right but it seems better and more clearly evokes our intentions, so use `to_owned` here.
-rw-r--r--src/tests.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/tests.rs b/src/tests.rs
index d59fcc6..29723cd 100644
--- a/src/tests.rs
+++ b/src/tests.rs
@@ -45,9 +45,9 @@ fn new_alias_with_special_characters() {
fn is_alias_in_file_finds_a_match() {
is_alias_in_file(
&Alias {
- alias: "farnsworth-hubert".to_string(),
- name: "Hubert Farnsworth".to_string(),
- email: "<professor@planetexpress.com>".to_string()
+ alias: "farnsworth-hubert".to_owned(),
+ name: "Hubert Farnsworth".to_owned(),
+ email: "<professor@planetexpress.com>".to_owned()
},
"./testdata/aliases"
);