aboutsummaryrefslogtreecommitdiff
path: root/src/ident.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/ident.rs')
-rw-r--r--src/ident.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/ident.rs b/src/ident.rs
index 19756ca..6a01d12 100644
--- a/src/ident.rs
+++ b/src/ident.rs
@@ -1,4 +1,5 @@
use regex::Regex;
+use std::borrow::ToOwned;
static PATTERN: Regex = regex!(":(.*)!(.*)@(.*)");
@@ -16,9 +17,9 @@ impl Ident {
None => return None
};
Some(Ident {
- nickname: c.at(1).unwrap().into_string(),
- user: c.at(2).unwrap().into_string(),
- host: c.at(3).unwrap().into_string()
+ nickname: c.at(1).unwrap().to_owned(),
+ user: c.at(2).unwrap().to_owned(),
+ host: c.at(3).unwrap().to_owned()
})
}
}