From f00dddd09cbeace6d63e3b454491468158f2c30d Mon Sep 17 00:00:00 2001
From: Oscar Perez
Date: Mon, 7 Jan 2013 13:24:40 -0500
Subject: [PATCH] Moved console existence check before the variable is used.
This was causing a crash in Internet Explorer when the console was not
enabled (console is off by default).
---
src/static/js/html10n.js | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/static/js/html10n.js b/src/static/js/html10n.js
index bb4acf819..c45f4b31b 100644
--- a/src/static/js/html10n.js
+++ b/src/static/js/html10n.js
@@ -23,10 +23,10 @@
window.html10n = (function(window, document, undefined) {
var console = window.console
function interceptConsole(method){
- var original = console[method]
-
if (!console) return function() {}
+ var original = console[method]
+
// do sneaky stuff
if (original.bind){
// Do this for normal browsers