Added indexOf function prototype