Fixing up indexing