By using getJIDWithHighestPriority we are sending messages to the highest priority JID without accounting for whatever settings the server might have. This defeats the purpose of that setting and should be stopped. It's all over the place, so I can't tie it to a single transport. Lots of mods will need to be made, but should be simple. Just change to getJID().