cleaned indexing procedure