Skip to content

Commit

Permalink
fix: Made http delete request return better information
Browse files Browse the repository at this point in the history
  • Loading branch information
batje committed Apr 6, 2019
1 parent e732f2b commit 7e6b4cf
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/CognosRequest.js
Original file line number Diff line number Diff line change
Expand Up @@ -340,9 +340,7 @@ class CognosRequest {
result = response;
} else {
try {
result = response.replace(/=\\'/g, "='");
result = result.replace(/\\']/g, "']");
result = JSON.parse(result);
result = response.data;
} catch (err) {
me.log('No valid JSON returned from delete request. ' + path);
result = response;
Expand Down

0 comments on commit 7e6b4cf

Please sign in to comment.