Created
October 13, 2011 18:10
-
-
Save thejefflarson/1284983 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// In case any **console.log** calls slip through there should be a dummy console object | |
// so any said call doesn't bust the page. | |
(function(){ | |
if(!window.console){ | |
var console = window.console = {}; | |
_.each(["log", "debug", "info", "warn", "error", "exception", "assert", "dir", | |
"dirxml", "trace", "group", "groupEnd", "groupCollapsed", "time", | |
"timeEnd", "profile", "profileEnd", "count", "clear", "notifyFirebug", | |
"getFirebugElement", "firebug", "element"], function(fn){ | |
console[fn] = function(){}; | |
}); | |
} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment