Added a patch for IE - in some version function indexOf() is not available.