Merge branch 'master' of https://github.com/danvk/dygraphs into i382
[dygraphs.git] / dygraph-utils.js
index 5bd58d7..9079aaf 100644 (file)
@@ -79,7 +79,7 @@ Dygraph.log = function(severity, message) {
     // In older versions of Firefox, only console.log is defined.
     var console = window.console;
     var log = function(console, method, msg) {
-      if (method) {
+      if (method && typeof(method) == 'function') {
         method.call(console, msg);
       } else {
         console.log(msg);