This is a completely new project. Here are the exact commands that I executed:
rails new MyProject
bundle install
rails generate controller Image
I added this route:
root :to => "image#process"
I added this function to ImageController
( image_controller.rb
)
def process render :nothing => true end
And finally, I removed the default index.html
. When I run the project, it has an error stating that the process expects 0 parameters, not 1. Therefore, I change the method to tell me which parameter the process is trying to send.
def process(arg) p arg render :nothing => true end
The line "process" is printed on the screen. I have done several Rails projects before and have never come across this. Did I miss something? Is this something new in Rails 3.0.10? Or can it be caused by Ruby 1.9.2? I usually use 1.8.7.
Spidy source share