Replacing getIndex function