236 shaares
110 liens privés
110 liens privés
1 résultat
taggé
technique
example : where is #render ?
def index
p method(:render).source_location
render params[:id]
end
then curl http://localhost:3000/users/xxxx
(or wherever your index is) and check your server output :
Processing by UsersController#show as */*
Parameters: {"id"=>"xxxx"}
["/Users/aaron/git/rails/actionpack/lib/action_controller/metal/instrumentation.rb", 40]
Completed 500 Internal Server Error in 35ms (ActiveRecord: 0.0ms)
from : https://tenderlovemaking.com/2016/02/05/i-am-a-puts-debuggerer.html