fix for json parsing errors in safari
This commit is contained in:
parent
a5fe12ee15
commit
b21695cad6
|
@ -680,18 +680,6 @@ requires
|
|||
|
||||
function success(data) {
|
||||
pending[options.id] = false;
|
||||
try {
|
||||
data = JSON.parse(data);
|
||||
} catch (err) {
|
||||
error({
|
||||
status: {
|
||||
code: 500,
|
||||
text: "Internal Server Error"
|
||||
},
|
||||
data: {}
|
||||
});
|
||||
return;
|
||||
}
|
||||
cache[req] = {
|
||||
data: data,
|
||||
time: Ox.getTime()
|
||||
|
@ -716,6 +704,7 @@ requires
|
|||
pending[options.id] = true;
|
||||
$.ajax({
|
||||
data: options.data,
|
||||
dataType: "json",
|
||||
error: error,
|
||||
success: success,
|
||||
timeout: options.timeout,
|
||||
|
|
Loading…
Reference in New Issue
Block a user