Create a gist now

Instantly share code, notes, and snippets.

invitations/create.js.erb
<% if @invitaion.valid? %>
window.location.replace("<%= signin_url %>")
<% else %>
var modal = "<%= render(:partial => 'invitations/form', :locals => {:invitation => @invitation) %>";
$('#signin-modal').html($(modal));
<% end %>
@mcbsys
mcbsys commented Nov 16, 2012

Fixed a couple brackets on the var line:

<% if @invitaion.valid? %>
  window.location.replace("<%= signin_url %>")
<% else %>
  var modal = "<%= render :partial => 'invitations/form', :locals => { :invitation => @invitation } %>";
  $('#signin-modal').html($(modal));
<% end %>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment