[bug 889141] Fix get_doctype_stats

It was looking at the hard-coded READ_INDEX when it should look at the
index it's told to look at.