refactor(ui): remove unnecessary checks (i18n is always defined)
This commit is contained in:
@@ -152,7 +152,7 @@ function setCurrentSection(section) {
|
||||
// Update page title
|
||||
const titleKey = `nav.${section}`;
|
||||
const defaultTitle = section.charAt(0).toUpperCase() + section.slice(1);
|
||||
appElements.pageTitle.textContent = i18n ? i18n.t(titleKey) : defaultTitle;
|
||||
appElements.pageTitle.textContent = i18n.t(titleKey);
|
||||
appElements.pageTitle.setAttribute('data-i18n', titleKey);
|
||||
|
||||
// Hide sharedView when switching to any other section
|
||||
|
||||
Reference in New Issue
Block a user