From 1a2070b4d93ffe94dd83d99fda21f3738015fd66 Mon Sep 17 00:00:00 2001 From: Sam Date: Tue, 19 Aug 2014 11:12:56 +1000 Subject: [PATCH] FIX: exception in an interval --- app/assets/javascripts/discourse/controllers/login.js.es6 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/javascripts/discourse/controllers/login.js.es6 b/app/assets/javascripts/discourse/controllers/login.js.es6 index c74673c8b47..38d9ff794d4 100644 --- a/app/assets/javascripts/discourse/controllers/login.js.es6 +++ b/app/assets/javascripts/discourse/controllers/login.js.es6 @@ -105,7 +105,7 @@ export default DiscourseController.extend(ModalFunctionality, { "menubar=no,status=no,height=" + height + ",width=" + width + ",left=" + left + ",top=" + top); var self = this; var timer = setInterval(function() { - if(w.closed) { + if(!w || w.closed) { clearInterval(timer); self.set('authenticate', null); }