Fixed a bug that was ignoring tag_name on document index