Refined XML regex (Related to #368)

This commit is contained in:
Gregory Schier 2017-07-25 14:22:10 -07:00
parent 8707d3fdfe
commit e80861e89f

View File

@ -188,7 +188,7 @@ class ResponseViewer extends PureComponent {
// Try to detect content-types if there isn't one
if (!mode) {
if (body.match(/^\s*<\?xml version="\d\.\d".*\?>/)) {
if (body.match(/^\s*<\?xml [^?]*\?>/)) {
mode = 'application/xml';
} else {
try {