Answer the question
In order to leave comments, you need to log in
What is the error in the if condition?
Hello!
I prescribe:
checked: (params[:news][:news][category_ids] if params[:news][:news])
# undefined method `[]' for nil:NilClass
<% if params[:news][:news] %>
# тут что-то
<% end %>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question