FIX: Category counts were incorrect when the names were duplicates.