xmpp-parsers/jingle: Fix Jingle::set_reason() helper.

It would add a content currently…
This commit is contained in:
Emmanuel Gil Peyrot 2020-11-27 20:55:41 +01:00
parent 59ccccbedc
commit 026b7d3c12

View file

@ -586,8 +586,8 @@ impl Jingle {
} }
/// Set the reason in this Jingle container. /// Set the reason in this Jingle container.
pub fn set_reason(mut self, content: Content) -> Jingle { pub fn set_reason(mut self, reason: ReasonElement) -> Jingle {
self.contents.push(content); self.reason = Some(reason);
self self
} }
} }