Merge pull request #4707 from 21pages/email
fix JSON parse empty string
This commit is contained in:
commit
2c56159d6d
1 changed files with 1 additions and 1 deletions
|
|
@ -427,7 +427,7 @@ function httpRequest(url, type, params, _onSuccess, _onError, headers="") {
|
|||
if (status == " ") self.timer(0.1s, check_status);
|
||||
else {
|
||||
try {
|
||||
var data = JSON.parse(status);
|
||||
var data = JSON.parse(status || "{}");
|
||||
_onSuccess(data);
|
||||
} catch (e) {
|
||||
_onError(status, 0);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue