Here's the corresponding controller code:
if @song.update_attributes(params[:song]) respond_to do |format| format.js { render :action => 'success' } end else
Here is what in success.js.erb :
$("#song_updated_at").val( "<%= escape_javascript @song.updated_at %>" )
Here is the error I get:
ActionView::TemplateError ($_ value need to be String (nil given)) on line
Thoughts?
source share