Couple of minor tweaks

The first emits the data callback that `node-xmpp` passes when a new connection is confirmed as online. This is useful as we get info about the user's ID and JID, which can come in handy.

Secondly, I'm connecting via websockets and when that's the case, `self.conn.connection.socket` is undefined, so the lines that sort out keeping the connection alive error. I've wrapped them in a conditional which fixes the problem.