Introduce self-presence

[?]
Oct 30, 2018, 11:16 AM
DXTXUF2RPKYRUNNOZM3NGJXP77JW6NVA5P4JT24KUQAUMUFROTIQC

Dependencies

  • [2] H5FNCGYJ Refactor online awaiting to separate function
  • [3] E4YEIQYO Connect to xmpp server
  • [4] F5UQL2FB Manage xmpp connection in cmd processing loop
  • [5] 34NQKMVK Don't move XmppConnection everywhere
  • [*] AVBHYHOA Stop xmpp thread by shudown

Change contents

  • replacement in src/xmpp.rs at line 45
    [3.1084][2.0:236]()
    Self::online(client.split(), account).then(|r| match r {
    Ok(conn) => future::ok(future::Loop::Break(conn)),
    Err(acc) => future::ok(future::Loop::Continue(acc)),
    })
    [3.1084]
    [3.530]
    Self::online(client.split(), account)
    .and_then(Self::self_presence)
    .then(|r| match r {
    Ok(conn) => future::ok(future::Loop::Break(conn)),
    Err(acc) => future::ok(future::Loop::Continue(acc)),
    })
  • replacement in src/xmpp.rs at line 60
    [2.488][2.488:559]()
    ) -> impl Future<Item = XmppConnection, Error = config::Account> {
    [2.488]
    [2.559]
    ) -> impl Future<Item = Self, Error = config::Account> {
  • edit in src/xmpp.rs at line 89
    [2.1728]
    [3.643]
    }
    fn self_presence(self) -> impl Future<Item = Self, Error = config::Account> {
    future::ok(self)