mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2024-11-22 14:22:05 +01:00
Set localNodeVer after currentCapsVersion is set
This commit is contained in:
parent
49c2c35609
commit
164b7c6690
1 changed files with 3 additions and 1 deletions
|
@ -467,11 +467,13 @@ public class EntityCapsManager extends Manager {
|
|||
|
||||
DiscoverInfo discoverInfo = new DiscoverInfo();
|
||||
discoverInfo.setType(IQ.Type.result);
|
||||
discoverInfo.setNode(getLocalNodeVer());
|
||||
sdm.addDiscoverInfoTo(discoverInfo);
|
||||
|
||||
// getLocalNodeVer() will return a result only after currentCapsVersion is set. Therefore
|
||||
// set it first and then call getLocalNodeVer()
|
||||
currentCapsVersion = generateVerificationString(discoverInfo);
|
||||
final String localNodeVer = getLocalNodeVer();
|
||||
discoverInfo.setNode(localNodeVer);
|
||||
addDiscoverInfoByNode(localNodeVer, discoverInfo);
|
||||
if (lastLocalCapsVersions.size() > 10) {
|
||||
CapsVersionAndHash oldCapsVersion = lastLocalCapsVersions.poll();
|
||||
|
|
Loading…
Reference in a new issue