I’ve got a straightforward piece of code in my controller which will
consistently produce a SystemStackError.
@newmessage = @message.reply(params[:newmessage])
return unless request.post?
if @newmessage.save
flash[:notice] = “Message Sent”
redirect_to :index
end
The error is occuring on the redirect_to line, if I comment that line
out then everything behaves as it should. Does anyone have any ideas
on what could be causing this?
The error is occuring on the redirect_to line, if I comment that line
out then everything behaves as it should. Does anyone have any ideas
on what could be causing this?
You probably wanted to write redirect_to :action => :index