UAT5MV5OUZS4UW3ZOEMNG75WZOS6W4274FI6F65GQX3TH7KWSCXQC
CBWCXUZZBPQYFROVZFCIWHW3CPNAGXO3PUARLGOF4DUF6VVCYKVQC
FV6BJ5K64QG63YI2PTII44ZEBAYNJBQZ5FSBHW65EPHGBKFGUW4AC
BWDUANCV77MCLCYMRS2UNFIFW4ZC3KB2KEGEUI77FRO7KW6TUZJQC
5IKA4GO7DIMBBYB7OUF5S7N2LUWIZ5MKCCCTZCAYPZI2357MVFHAC
VS6AHRWIPIMQNQAFX7INQGSUB72OW2K6HM6NGOV76RBRF6COQFRQC
OANBCLN5TD5VQTSAQXSIXU6IUCXMKQSML2UJGQCKVTOCENEVABIAC
SU4DNVCBZYNXKBPMMNL2TAUVXYVDGBJR2P3BAZJKG7GJMYWELMKQC
EBETRYK7RNRATWD75LTFUTPF6M6KB6YPKTQUX4K232JB6CKVOZOQC
UIXIQHDY7E4DLLRQP4ATXF625QC4KGMHWOV24UEQ6WD7G2IPM4HAC
UMTLHH77LGABTVKULH6ONVSBTMSFGH3CJ6GPNTFWH73AWNJZV6LQC
FWJDW3G5KT66GHFS7IPPSFS3G5COH2BNN57GHTVT533FE7467QZAC
3FYEOGCIRRMOVYU2NB4MM477RSF4ZTSNJYFJ5NNXSB6WGR6MQYPQC
}
pub fn make_add_roster(id: &str, jid: jid::Jid) -> Element {
let mut add_roster = Iq::from_set(Roster {
items: vec![Item {
jid,
name: None,
subscription: xmpp_parsers::roster::Subscription::None,
groups: vec![],
}],
ver: None,
});
add_roster.id = Some(id.to_string());
add_roster.into()
.processing(XmppConnection::process_initial_roster, stop_future)
.processing(
move |conn, event| conn.process_initial_roster(event, &id_init_roster),
stop_future,
)
let XmppConnection {
account,
state: XmppState { client, mut data },
} = self;
data.counter += 1;
let id_add_roster = format!("id{}", data.counter);
let add_roster = stanzas::make_add_roster(&id_add_roster, cmd.xmpp_to.clone());
info!("Add jid to roster... {:?}", add_roster);
future::ok(XmppConnection {
account,
state: XmppState { client, data },
})