I know this is probably rather trivial but i have had a lookt at previous questions and i've tried them but they still issued an error unfortunately :s
My issue is the following, i have an html.erb file and i want a certain body text to be display given a condition or another if it is false
i have
<% if [email protected] do %>
more code goes here
<% end %>
I have tried many combinations but the most frequent error i keep getting is
You have a nil object when you didn't expect it!
The error occurred while evaluating nil.nil
I'm not sure what i'm doing wrong, this is most likely something very easy but i cant find my way through it! :s Any assistance would be really appreciated, thanks in advanced