stellard
stellard

Reputation: 5314

Rails Compile error for form_for

I am getting the an error on the following code in one of my partial views

<% form_for (@user) |form| %>

SyntaxError in User#edit

Showing user/_user_edit_form.html.erb where line #1 raised:

compile error ../app/views/user/_user_edit_form.html.erb:1: syntax error, unexpected ';' _erbout = ''; form_for (@user) |form| ; _erbout.concat "\n"

Does anyone know what this means?

Upvotes: 0

Views: 927

Answers (1)

Pesto
Pesto

Reputation: 23880

You forgot the do:

<% form_for (@user) do |form| %>

Upvotes: 1

Related Questions