Revert "package: remove version restrictor for "indexof""

This reverts commit 214e2cfef9d4470df296e095ca48f19973e6cbb6.