فهرست منبع

Fixes error with ie 9

The old line console.log produces error in ie because "console" is only
active if you opened developer tools with 'f12'
ardiman 11 سال پیش
والد
کامیت
928e71f36a
1فایلهای تغییر یافته به همراه2 افزوده شده و 1 حذف شده
  1. 2 1
      assets/scripts/foreground.js

+ 2 - 1
assets/scripts/foreground.js

@@ -5,7 +5,8 @@ jQuery(document).ready(function() {
 
 
   jQuery(document).foundation(function (response) {
-    console.log(response.errors);
+    // console.log(response.errors); < this line will produce error in ie9!
+    if (window.console) console.log(response.errors);
   });
 
   jQuery('[id^=ca-nstab] a').addClass('icon-file').text(' ' + jQuery('[id^=ca-nstab] a').text());