Merge pull request #3767 from thelounge/setname

Unprefix setname cap
This commit is contained in:
Pavel Djundik 2020-02-27 14:01:03 +02:00 committed by GitHub
commit 365613f0ee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -159,6 +159,7 @@ Network.prototype.createIrcFramework = function(client) {
rejectUnauthorized: this.rejectUnauthorized,
enable_chghost: true,
enable_echomessage: true,
enable_setname: true,
auto_reconnect: true,
auto_reconnect_wait: 10000 + Math.floor(Math.random() * 1000), // If multiple users are connected to the same network, randomize their reconnections a little
auto_reconnect_max_retries: 360, // At least one hour (plus timeouts) worth of reconnections
@ -166,7 +167,6 @@ Network.prototype.createIrcFramework = function(client) {
});
this.irc.requestCap([
"draft/setname", // https://github.com/ircv3/ircv3-specifications/pull/361
"znc.in/self-message", // Legacy echo-message for ZNC
]);
@ -256,7 +256,7 @@ Network.prototype.edit = function(client, args) {
if (
connected &&
this.realname !== oldRealname &&
this.irc.network.cap.isEnabled("draft/setname")
this.irc.network.cap.isEnabled("setname")
) {
this.irc.raw("SETNAME", this.realname);
}