Skip to content

Commit

Permalink
Use 'null' instead of '' for JSON.parse
Browse files Browse the repository at this point in the history
  • Loading branch information
danmarshall authored Aug 30, 2016
1 parent fe61805 commit 6d87eb5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/observable/dom/AjaxObservable.ts
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ export class AjaxResponse {
//IE does not support json as responseType, parse it internally
this.response = xhr.responseType ? xhr.response : JSON.parse(xhr.response || xhr.responseText || 'null');
} else {
this.response = JSON.parse(xhr.responseText || '');
this.response = JSON.parse(xhr.responseText || 'null');
}
break;
case 'xml':
Expand Down

0 comments on commit 6d87eb5

Please sign in to comment.