jQuery version check is faulty
-
Hello Devs of Afterpay
I your plugin in file afterpay-gateway-for-woocommerce\js\afterpay.js you perform a check for jQuery version like this:
if (typeof jQuery === 'undefined' || parseFloat(jQuery.fn.jquery) < 1.7) { Afterpay.loadScript('https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js', function() { var jQuery_1_12_4 = jQuery.noConflict(true); Afterpay.init(jQuery_1_12_4); }); } else { Afterpay.init(jQuery); }That is wrong, because version ‘1.12.4’ processed by parseFloat becomes 1.12, and 1.12 is less than 1.7 mathematically. But version-wise it’s not
This causes website to load jQuery twice
Please fix this
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘jQuery version check is faulty’ is closed to new replies.