ember-auth-rails 3.6.1 → 3.7.0
Sign up to get free protection for your applications and to get access to all the features.
@@ -106,6 +106,11 @@
|
|
106
106
|
}
|
107
107
|
},
|
108
108
|
ajax: function(url, type, hash) {
|
109
|
+
var token;
|
110
|
+
if (token = this.get('authToken')) {
|
111
|
+
hash.data || (hash.data = {});
|
112
|
+
hash.data[Auth.Config.get('tokenKey')] = this.get('authToken');
|
113
|
+
}
|
109
114
|
hash.url = url;
|
110
115
|
hash.type = type;
|
111
116
|
hash.dataType = 'json';
|
@@ -175,11 +180,6 @@
|
|
175
180
|
|
176
181
|
Auth.RESTAdapter = DS.RESTAdapter.extend({
|
177
182
|
ajax: function(url, type, hash) {
|
178
|
-
var token;
|
179
|
-
if (token = Auth.get('authToken')) {
|
180
|
-
hash.data || (hash.data = {});
|
181
|
-
hash.data[Auth.Config.get('tokenKey')] = Auth.get('authToken');
|
182
|
-
}
|
183
183
|
hash.context = this;
|
184
184
|
return Auth.ajax(url, type, hash);
|
185
185
|
}
|
data/lib/ember-auth/version.rb
CHANGED