Skip to content

Commit

Permalink
Properly handle feature-not-implemented error on jid type recovery
Browse files Browse the repository at this point in the history
  • Loading branch information
tmolitor-stud-tu committed Feb 19, 2025
1 parent d2c9724 commit b84b2af
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Monal/Classes/xmpp.m
Original file line number Diff line number Diff line change
Expand Up @@ -4551,6 +4551,8 @@ -(AnyPromise*) checkJidType:(NSString*) jid
//this means the jid is an account which can not be queried if not subscribed
if([error check:@"/<type=error>/error<type=cancel>/{urn:ietf:params:xml:ns:xmpp-stanzas}service-unavailable"])
return resolve(@"account");
else if([error check:@"/<type=error>/error<type=cancel>/{urn:ietf:params:xml:ns:xmpp-stanzas}feature-not-implemented"])
return resolve(@"account");
else if([error check:@"/<type=error>/error<type=auth>/{urn:ietf:params:xml:ns:xmpp-stanzas}subscription-required"])
return resolve(@"account");
//any other error probably means the remote server is not reachable or (even more likely) the jid is incorrect
Expand Down

0 comments on commit b84b2af

Please sign in to comment.