Minor change to the getIndexNames() method to take advantage of the Set<>.toArray method.