Убраны console.warn из chatListFilter и chatListRealtime

Модули теперь тихо выходят, если не находят элементы (не на странице чатов),
вместо того чтобы засорять консоль предупреждениями на всех остальных страницах.
This commit is contained in:
admin i 2025-11-30 12:21:36 +03:00
parent 6f1e477fe8
commit d35d7cb9b9
2 changed files with 2 additions and 2 deletions

View File

@ -32,7 +32,7 @@ export function initChatListFilter(options = {}) {
const labels = document.querySelectorAll(filterSelector);
if (!search || !labels.length) {
console.warn(`ChatListFilter: elements not found`);
// Тихо выходим если не на странице чатов
return null;
}

View File

@ -24,7 +24,7 @@ export function initChatListRealtime(options = {}) {
// Проверяем наличие списка чатов
const listAny = document.querySelector(chatRowSelector);
if (!listAny) {
console.warn('ChatListRealtime: no chat rows found, skipping');
// Тихо выходим если не на странице чатов
return null;
}