Crete index object when needed