Skip to content

Commit

Permalink
Fixed input name selector in csrf form update
Browse files Browse the repository at this point in the history
  • Loading branch information
JangoSteve committed Apr 25, 2012
1 parent bb13c9d commit 7a4c6f4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rails.js
Expand Up @@ -378,7 +378,7 @@
// making sure that all forms have actual up-to-date token(cached forms contain old one)
csrf_token = $('meta[name=csrf-token]').attr('content');
csrf_param = $('meta[name=csrf-param]').attr('content');
$('form input[name='+csrf_param+']').val(csrf_token);
$('form input[name="' + csrf_param + '"]').val(csrf_token);
});

})( jQuery );

0 comments on commit 7a4c6f4

Please sign in to comment.