aboutsummaryrefslogtreecommitdiff
path: root/src/ident.rs
diff options
context:
space:
mode:
authorJames Ravenscroft2014-12-25 11:39:05 +0000
committerJames Ravenscroft2014-12-25 11:39:05 +0000
commitce4ab4d6a395bbce37531225d506552d6a910f3f (patch)
tree657bd88ef56ddbd7eac1ec1c18158c2fe40e4389 /src/ident.rs
parent6ed12a0993d56330bb008adc86bfb5ebe4320583 (diff)
downloadirsc-ce4ab4d6a395bbce37531225d506552d6a910f3f.tar.gz
irsc-ce4ab4d6a395bbce37531225d506552d6a910f3f.tar.xz
irsc-ce4ab4d6a395bbce37531225d506552d6a910f3f.zip
Added unwrap calls around ident regex matches
Diffstat (limited to 'src/ident.rs')
-rw-r--r--src/ident.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ident.rs b/src/ident.rs
index 069e186..3089af4 100644
--- a/src/ident.rs
+++ b/src/ident.rs
@@ -16,9 +16,9 @@ impl Ident {
None => return None
};
Some(Ident {
- nickname: c.at(1).into_string(),
- user: c.at(2).into_string(),
- host: c.at(3).into_string()
+ nickname: c.at(1).unwrap_or("").into_string(),
+ user: c.at(2).unwrap_or("").into_string(),
+ host: c.at(3).unwrap_or("").into_string()
})
}
}