mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 06:39:48 +00:00
Refined XML regex (Related to #368)
This commit is contained in:
parent
8707d3fdfe
commit
e80861e89f
@ -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 {
|
||||
|
Loading…
Reference in New Issue
Block a user