delint (clippy)

This commit is contained in:
Astro 2017-07-21 00:19:08 +02:00
commit 7cd31bd425
8 changed files with 55 additions and 64 deletions

View file

@ -9,22 +9,22 @@ pub enum Event {
impl Event {
pub fn is_online(&self) -> bool {
match self {
&Event::Online => true,
match *self {
Event::Online => true,
_ => false,
}
}
pub fn is_stanza(&self, name: &str) -> bool {
match self {
&Event::Stanza(ref stanza) => stanza.name() == name,
match *self {
Event::Stanza(ref stanza) => stanza.name() == name,
_ => false,
}
}
pub fn as_stanza(&self) -> Option<&Element> {
match self {
&Event::Stanza(ref stanza) => Some(stanza),
match *self {
Event::Stanza(ref stanza) => Some(stanza),
_ => None,
}
}