Fix duplicate chat containers and unread markers when reconnecting
Fixes #1721
This commit is contained in:
parent
79a2c72c06
commit
a9198b1cf6
@ -228,19 +228,21 @@ function renderNetworks(data, singleNetwork) {
|
|||||||
newChannels = channels;
|
newChannels = channels;
|
||||||
}
|
}
|
||||||
|
|
||||||
chat.append(
|
if (newChannels.length > 0) {
|
||||||
templates.chat({
|
chat.append(
|
||||||
channels: channels,
|
templates.chat({
|
||||||
})
|
channels: newChannels,
|
||||||
);
|
})
|
||||||
|
);
|
||||||
|
|
||||||
newChannels.forEach((channel) => {
|
newChannels.forEach((channel) => {
|
||||||
renderChannel(channel);
|
renderChannel(channel);
|
||||||
|
|
||||||
if (channel.type === "channel") {
|
if (channel.type === "channel") {
|
||||||
chat.find("#chan-" + channel.id).data("needsNamesRefresh", true);
|
chat.find("#chan-" + channel.id).data("needsNamesRefresh", true);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
utils.confirmExit();
|
utils.confirmExit();
|
||||||
sorting();
|
sorting();
|
||||||
|
Loading…
Reference in New Issue
Block a user