Refactored all_tag_counts to avoid scope if it already knows the id. A