NameError: uninitialized constant Category::Category #169

rutgerg opened this Issue Dec 17, 2012 · 6 comments


None yet

4 participants

rutgerg commented Dec 17, 2012 edited


love the gem. Txs. Everything works except for 1 thing. Whenever I try to use the move_to_child_of method exactly as in the cheat sheet I get an error saying NameError: uninitialized constant Category::Category. What is going wrong here?



parndt commented Dec 17, 2012

Not sure - can we see the code in your Category class?

rutgerg commented Dec 17, 2012

Pretty straight forward:

class Category < ActiveRecord::Base
  attr_accessible :name, :ics_url, :image_url

parndt commented Jun 25, 2013

I can't think why.

drinks commented Jul 12, 2013

Ran into this just now (on save) and thought I'd mention what we found in case it helps--our project was using this snippet to automatically reload the app, and somehow reloading the including model was the cause. Can't say for sure what's happening, but removing the initializer fixed it.


Has this issue been fixed, cause I am having same problem in my app.

rutgerg commented Jul 21, 2016

This is such a long time ago that I can't remember what I did to solve it at that time. I don't use the gem anymore. Sorry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment