Get the index properly.