From e88b11c3a767595a2d0bf42e3f87ef0b6c4b7d1b Mon Sep 17 00:00:00 2001 From: Ian Gulliver Date: Fri, 8 Jan 2016 14:34:16 -0800 Subject: [PATCH] Better type checking for logout event. --- static/babystats.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/static/babystats.js b/static/babystats.js index ffd65f4..df895be 100644 --- a/static/babystats.js +++ b/static/babystats.js @@ -199,7 +199,8 @@ BabyStats.prototype.onLogin_ = function(e) { * @private */ BabyStats.prototype.onLogout_ = function(e) { - this.loginURL_ = e.detail.login_url; + var detail = /** @type {Cosmopolite.typeEventLogoutDetail} */ (e.detail); + this.loginURL_ = detail.login_url; this.loginRule_.style.visibility = 'visible'; this.checkOverlay_(); };