diff options
-rw-r--r-- | twittperator.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/twittperator.js b/twittperator.js index fc439db..969bd56 100644 --- a/twittperator.js +++ b/twittperator.js @@ -1237,8 +1237,9 @@ let PLUGIN_INFO = url + '.json', query, function (text) { + let json; try { - return callback(JSON.parse(text)); + json = JSON.parse(text); } catch (e) { (onError || @@ -1248,6 +1249,7 @@ let PLUGIN_INFO = throw e; })(e); } + return callback(json); } ); }; |