RailsCasts Pro episodes are now free!

Learn more or hide this

Patrick Dougall's Profile

GitHub User: pdougall1

Comments by Patrick Dougall

Avatar

Thanks for the simple contribution! I've never messed with coffescript before and I'd have had no idea that spaces instead of tabs would mess my code up so much!

Avatar

I got this working great in the rails console, right off the bat. Fell in love immediately. Then when I implemented it in the views I kept getting "wrong number of arguments 0 for 1". Googling around I found I wasn't the only one, lots of people were getting that error and I couldn't really find a strait answer.

Eventually I restarted the rails session and BOOM, it works!

So
"wrong number of arguments 0 for 1" => try restarting session.