Handle private message in a better way
Private messages should work in all these ways, to talk with foobar on the serveur irc.example:
- foobar%irc.example@example.com
- irc.example@example.com/foobar
- #some_chan%irc.example@example.com/foobar
All these JIDs should forward the message to the same IRC user.
With the following notes:
- Only the last two version can be used to talk with someone with a nick containing uppercase (because of nodeprep which makes everything lowercase)
- Messages from foobar should come from the irc.example@example.com/foobar jid UNLESS the biboumi user previously sent a message to #some_chan%irc.example@example.com/foobar, in which case biboumi should remember this value (specifically the #some_chan part) and foobar’s message should come from this jid instead. This avoids having two tabs in the XMPP client, one with #some_chan%irc.example@example.com/foobar because we used /query foobar on #some_chan, and one with irc.example@example.com/foobar because biboumi is dumb.
(from redmine: created on 2014-02-19, closed on 2014-06-18)