Better without clones

This commit is contained in:
Maxime “pep” Buquet 2017-06-12 17:46:06 +01:00
parent 072cba6a3e
commit 10ab104ea0

View file

@ -206,8 +206,8 @@ impl Jid {
/// assert_eq!(jid.resource, None); /// assert_eq!(jid.resource, None);
pub fn get_bare(self) -> Jid { pub fn get_bare(self) -> Jid {
Jid { Jid {
node: self.node.clone(), node: self.node,
domain: self.domain.clone(), domain: self.domain,
resource: None, resource: None,
} }
} }
@ -253,7 +253,7 @@ impl Jid {
pub fn get_domain(self) -> Jid { pub fn get_domain(self) -> Jid {
Jid { Jid {
node: None, node: None,
domain: self.domain.clone(), domain: self.domain,
resource: None, resource: None,
} }
} }