diff options
author | James Ravenscroft | 2014-12-25 18:33:49 +0000 |
---|---|---|
committer | James Ravenscroft | 2014-12-25 18:33:49 +0000 |
commit | 8d42ad9822e7e4b9e595bb2bd587a5da0db8ce9a (patch) | |
tree | cad10a4dc037254b06b18a366a83a86bfb4116ca /src/ident.rs | |
parent | 7181a9824cb7bda6e10f83f0a4d11e3fd493dcbf (diff) | |
download | irsc-8d42ad9822e7e4b9e595bb2bd587a5da0db8ce9a.tar.gz irsc-8d42ad9822e7e4b9e595bb2bd587a5da0db8ce9a.tar.xz irsc-8d42ad9822e7e4b9e595bb2bd587a5da0db8ce9a.zip |
Changed unwrap_or to unwrap because we want the program to fail instead of use emptystring if ident can't be unwrapped
Diffstat (limited to 'src/ident.rs')
-rw-r--r-- | src/ident.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ident.rs b/src/ident.rs index 3089af4..19756ca 100644 --- a/src/ident.rs +++ b/src/ident.rs @@ -16,9 +16,9 @@ impl Ident { None => return None }; Some(Ident { - nickname: c.at(1).unwrap_or("").into_string(), - user: c.at(2).unwrap_or("").into_string(), - host: c.at(3).unwrap_or("").into_string() + nickname: c.at(1).unwrap().into_string(), + user: c.at(2).unwrap().into_string(), + host: c.at(3).unwrap().into_string() }) } } |