I have a model called "Comment" in my Rails 3.2 app and it works in my application. However, I made a script, run by rails runner
, which inserts data such as comments in my database and I get the following error :
/home/revan/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/rexml/comment.rb:23:in `initialize': wrong number of arguments (0 for 1) (ArgumentError)
I found that the problem comes from the Comment defined in REXML which is overshadowing my own Comment model.
I made lots of researches on the Internet but I found no convenient solution. So my question is : How can I avoid the overshadowing of my Comment without changing the name of my model ?
Thank you,
Revan