Parcourir la source

Make sure that console is available

Nicolas Petton il y a 13 ans
Parent
commit
e6db8eeddb
1 fichiers modifiés avec 13 ajouts et 0 suppressions
  1. 13 0
      js/boot.js

+ 13 - 0
js/boot.js

@@ -33,6 +33,19 @@
    |
    ==================================================================== */
 
+/* Make that console is available */
+
+if (typeof console == "undefined") {
+    this.console = {
+	log: function() {},
+	warn: function() {},
+	info: function() {},
+	debug: function() {},
+	error: function() {},
+    };
+}
+
+
 /* Smalltalk constructors definition */
 
 function SmalltalkObject(){};