We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents aa8f4fe + 8fdd2d8 commit f3a9a0cCopy full SHA for f3a9a0c
vendor/assets/javascripts/ng-rails-csrf.js
@@ -16,7 +16,7 @@ angular.module('ng-rails-csrf', [] ).config(['$httpProvider', function($httpProv
16
var updateToken = function() {
17
var headers = $httpProvider.defaults.headers.common, token = getToken();
18
if (token) {
19
- headers['X-CSRF-TOKEN'] = getToken();
+ headers['X-CSRF-TOKEN'] = token;
20
headers['X-Requested-With'] = 'XMLHttpRequest';
21
}
22
};
0 commit comments