2017-05-18 20:08:54 +00:00
|
|
|
"use strict";
|
|
|
|
|
|
|
|
const $ = require("jquery");
|
|
|
|
const socket = require("../socket");
|
|
|
|
|
|
|
|
socket.on("nick", function(data) {
|
|
|
|
const id = data.network;
|
|
|
|
const nick = data.nick;
|
2018-04-28 08:19:49 +00:00
|
|
|
const network = $(`#sidebar .network[data-uuid="${id}"]`).attr("data-nick", nick);
|
2018-02-20 07:28:04 +00:00
|
|
|
|
2017-05-18 20:08:54 +00:00
|
|
|
if (network.find(".active").length) {
|
2018-03-16 14:10:28 +00:00
|
|
|
$("#nick").text(nick);
|
2017-05-18 20:08:54 +00:00
|
|
|
}
|
|
|
|
});
|