added reindex to init code