Sfoglia il codice sorgente

Update scripts.js

Fixed error: "jQuery Uncaught TypeError: Property '$' of object [object Window] is not a function"

I noticed it because it prevents the woocommerce button to appear when selecting a product variation (https://github.com/woothemes/woocommerce/issues/1074)
andamira 12 anni fa
parent
commit
52cc8a53b0
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      library/js/scripts.js

+ 1 - 1
library/js/scripts.js

@@ -115,7 +115,7 @@ function loadGravatars() {
   // if the viewport is tablet or larger, we load in the gravatars
 	if (viewport.width >= 768) {
 		$('.comment img[data-gravatar]').each(function(){
-      $(this).attr('src',$(this).attr('data-gravatar'));
+      jQuery(this).attr('src',$(this).attr('data-gravatar'));
     });
 	}
 } // end function