Fix undefined channel when updating title
This commit is contained in:
parent
65bd014a21
commit
4f018ba23b
@ -104,7 +104,7 @@ function updateTitle() {
|
|||||||
let title = $(document.body).data("app-name");
|
let title = $(document.body).data("app-name");
|
||||||
const chanTitle = $("#sidebar").find(".chan.active").attr("aria-label");
|
const chanTitle = $("#sidebar").find(".chan.active").attr("aria-label");
|
||||||
|
|
||||||
if (chanTitle.length > 0) {
|
if (chanTitle && chanTitle.length > 0) {
|
||||||
title = `${chanTitle} — ${title}`;
|
title = `${chanTitle} — ${title}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user