From 1e2935c018475fc293818f8530b684c5d308437b Mon Sep 17 00:00:00 2001 From: Stefan Breunig Date: Fri, 8 Mar 2013 10:46:52 +0100 Subject: [PATCH] =?UTF-8?q?don=E2=80=99t=20try=20to=20request=20more=20cha?= =?UTF-8?q?t=20messages=20when=20no=20chat=20is=20active.=20This=20only=20?= =?UTF-8?q?affected=20smartphones.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- code/chat.js | 1 + 1 file changed, 1 insertion(+) diff --git a/code/chat.js b/code/chat.js index 00c0e5a9..dc01f3f2 100644 --- a/code/chat.js +++ b/code/chat.js @@ -389,6 +389,7 @@ window.chat.needMoreMessages = function() { if(activeTab === 'debug') return; var activeChat = $('#chat > :visible'); + if(activeChat.length === 0) return; var hasScrollbar = scrollBottom(activeChat) !== 0 || activeChat.scrollTop() !== 0; var nearTop = activeChat.scrollTop() <= CHAT_REQUEST_SCROLL_TOP;