wechaty-puppet-matrix 0.0.27 → 0.0.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -442,8 +442,8 @@ class Client extends events_1.EventEmitter {
|
|
|
442
442
|
username: this.tokenInfo.mqUser,
|
|
443
443
|
password: this.tokenInfo.mqPsd,
|
|
444
444
|
keepalive: 60,
|
|
445
|
-
reconnectPeriod:
|
|
446
|
-
connectTimeout:
|
|
445
|
+
reconnectPeriod: 100,
|
|
446
|
+
connectTimeout: 60 * 1000,
|
|
447
447
|
clientId: this.tokenInfo.guid + randomRange(1, 10000),
|
|
448
448
|
});
|
|
449
449
|
client.on('connect', () => {
|
|
@@ -795,7 +795,7 @@ class PuppetMatrix extends PUPPET.Puppet {
|
|
|
795
795
|
if (contact) {
|
|
796
796
|
return '@' + (contact.alias || contact.name);
|
|
797
797
|
}
|
|
798
|
-
return
|
|
798
|
+
return mentionId === '@all' ? 'notify@all' : '';
|
|
799
799
|
}));
|
|
800
800
|
const mentionText = mentionContact.join(String.fromCharCode(0x2005));
|
|
801
801
|
text = text.replaceAll(mentionText, '').trim();
|
|
@@ -403,8 +403,8 @@ class Client extends EventEmitter {
|
|
|
403
403
|
username: this.tokenInfo.mqUser,
|
|
404
404
|
password: this.tokenInfo.mqPsd,
|
|
405
405
|
keepalive: 60,
|
|
406
|
-
reconnectPeriod:
|
|
407
|
-
connectTimeout:
|
|
406
|
+
reconnectPeriod: 100,
|
|
407
|
+
connectTimeout: 60 * 1000,
|
|
408
408
|
clientId: this.tokenInfo.guid + randomRange(1, 10000),
|
|
409
409
|
});
|
|
410
410
|
client.on('connect', () => {
|
|
@@ -755,7 +755,7 @@ class PuppetMatrix extends PUPPET.Puppet {
|
|
|
755
755
|
if (contact) {
|
|
756
756
|
return '@' + (contact.alias || contact.name);
|
|
757
757
|
}
|
|
758
|
-
return
|
|
758
|
+
return mentionId === '@all' ? 'notify@all' : '';
|
|
759
759
|
}));
|
|
760
760
|
const mentionText = mentionContact.join(String.fromCharCode(0x2005));
|
|
761
761
|
text = text.replaceAll(mentionText, '').trim();
|
package/package.json
CHANGED
|
@@ -759,8 +759,8 @@ class Client extends EventEmitter {
|
|
|
759
759
|
username: this.tokenInfo.mqUser,
|
|
760
760
|
password: this.tokenInfo.mqPsd,
|
|
761
761
|
keepalive: 60,
|
|
762
|
-
reconnectPeriod:
|
|
763
|
-
connectTimeout:
|
|
762
|
+
reconnectPeriod: 100,
|
|
763
|
+
connectTimeout: 60 * 1000,
|
|
764
764
|
clientId: this.tokenInfo.guid + randomRange(1, 10000),
|
|
765
765
|
})
|
|
766
766
|
|
package/src/puppet-matrix.ts
CHANGED
|
@@ -983,7 +983,7 @@ class PuppetMatrix extends PUPPET.Puppet {
|
|
|
983
983
|
if (contact) {
|
|
984
984
|
return '@' + (contact.alias || contact.name)
|
|
985
985
|
}
|
|
986
|
-
return
|
|
986
|
+
return mentionId === '@all' ? 'notify@all' : ''
|
|
987
987
|
}))
|
|
988
988
|
const mentionText = mentionContact.join(String.fromCharCode(0x2005))
|
|
989
989
|
|