Error after upgrading Magento to latest version
Sometime when you upgrade Magento to latest version you will have this error in the console
"Uncaught TypeError: url.indexOf is not a function"
this error comes because of jQuery version
to solve the problem please follow the steps below
Solution:
Search your custom code and replace the following deprecated excerpt:
$(window).load(function(){...}); or jQuery(window).load(function(){...});
with the following:
$(window).on('load', function(){ ...}); || jQuery(window).on('load', function(){ ...});