tried fix in get index method