And Michał Kazior spoke on 06/05/2011 03:01 PM, saying: > Hello, > > I'm trying to strip a jid resource, example: > [email protected]/HomeXYZ -> [email protected] > > I know that I could just split it, but that seems wrong to me. > Shouldn't it be possible to do it with libpurple alone?
The API libpurple exposes is generally protocol-neutral, but in this case, you can generally call purple_normalize(account, "[email protected]/Home"), which will return the bare JID. Note that if you pass a valid account AND the JID is part of an active MUC (i.e. you're in it), you'll get the full JID. That said, what the protocol plugin does is baiscally just split on @ and /, so... ~Paul
signature.asc
Description: OpenPGP digital signature
_______________________________________________ [email protected] mailing list Want to unsubscribe? Use this link: http://pidgin.im/cgi-bin/mailman/listinfo/support
