mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2025-09-10 18:59:41 +02:00
Bump jxmpp to 0.5.0-alpha5 and change Roster API
to only allow bare JIDs as roster entires.
This commit is contained in:
parent
2f219c7317
commit
58402c5615
16 changed files with 111 additions and 114 deletions
|
@ -48,7 +48,7 @@ public class FromMatchesFilter implements StanzaFilter {
|
|||
*/
|
||||
public FromMatchesFilter(Jid address, boolean ignoreResourcepart) {
|
||||
if (address != null && ignoreResourcepart) {
|
||||
this.address = address.withoutResource();
|
||||
this.address = address.asBareJid();
|
||||
}
|
||||
else {
|
||||
this.address = address;
|
||||
|
@ -99,7 +99,7 @@ public class FromMatchesFilter implements StanzaFilter {
|
|||
}
|
||||
|
||||
if (ignoreResourcepart) {
|
||||
from = from.withoutResource();
|
||||
from = from.asBareJid();
|
||||
}
|
||||
return from.equals(address);
|
||||
}
|
||||
|
|
|
@ -44,7 +44,7 @@ public class BindIQProvider extends IQProvider<Bind> {
|
|||
bind = Bind.newSet(Resourcepart.from(resourceString));
|
||||
break;
|
||||
case "jid":
|
||||
EntityFullJid fullJid = JidCreate.fullFrom(parser.nextText());
|
||||
EntityFullJid fullJid = JidCreate.entityFullFrom(parser.nextText());
|
||||
bind = Bind.newResult(fullJid);
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -76,7 +76,7 @@ public class ParserUtils {
|
|||
if (jidString == null) {
|
||||
return null;
|
||||
}
|
||||
return JidCreate.bareFrom(jidString);
|
||||
return JidCreate.entityBareFrom(jidString);
|
||||
}
|
||||
|
||||
public static Resourcepart getResourcepartAttribute(XmlPullParser parser, String name) throws XmppStringprepException {
|
||||
|
|
|
@ -67,7 +67,7 @@ public class DummyConnection extends AbstractXMPPConnection {
|
|||
|
||||
private EntityFullJid getUserJid() {
|
||||
try {
|
||||
return JidCreate.fullFrom(config.getUsername()
|
||||
return JidCreate.entityFullFrom(config.getUsername()
|
||||
+ "@"
|
||||
+ config.getXMPPServiceDomain()
|
||||
+ "/"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue