I'm submitting a parameter show_all
with the value true
. This value isn't associated with a model.
My controller is assigning this parameter to an instance variable:
@show_all = params[:show_all]
However, @show_all.is_a? String
, and if @show_all == true
always fails.
What values does Rails parse as booleans? How can I explicitly specify that my parameter is a boolean, and not a string?