Source
84
84
request.success = this.processRespond.bind(this);
85
85
request.error = this.processError.bind(this);
86
86
}
87
87
88
88
var params = this.userParams;
89
89
if (typeof this.userParams.request === 'object') {
90
90
Object.keys(params.request).forEach(function (key) {
91
91
request[key] = params.request[key];
92
92
});
93
93
}
94
-
request.data = JSON.stringify(body),
94
+
request.data = JSON.stringify(body);
95
95
96
96
new jQuery.ajax(RPC.rpcurl(), request);
97
97
},
98
98
99
99
processRespond: function(_, _, resp){
100
100
var isError = this.processError(resp);
101
101
if (isError) {
102
102
return false;
103
103
}
104
104
125
125
this.userParams.onFailure(resp.responseJSON.error);
126
126
return true;
127
127
}
128
128
else if (!isset('result', resp.responseJSON)) {
129
129
throw('RPC: Server call [' + this.userParams.method + '] responded with incorrect JSON.');
130
130
}
131
131
132
132
return false;
133
133
}
134
134
};
135
-