Skip to content

Tag_Counts not acting as advertised #185

seanahrens opened this Issue Aug 29, 2011 · 2 comments

3 participants


When I call .tag_counts, I get a list of tags without any counts:

u =
u.skill_list = "nunchucks, dogg fighting"
=> [#, #]

But the readme says this should be the expected output:

@frankie = User.create(:name => "Frankie", :skill_list => "joking, flying, eating")
User.skill_counts # => [,...]

artemk commented Dec 18, 2011

count is returning. It is not shown in Inspect, because count is taken from sql. Try to run User.skill_counts.first.count and you will get what you are expecting.

@artemk artemk closed this Dec 18, 2011
guyisra commented Oct 23, 2012

How would I get the count for each tag? Must I do something like{|x| [, x.count]} ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.