unprint 0.15.2 → 0.15.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/app.js +3 -3
package/package.json
CHANGED
package/src/app.js
CHANGED
|
@@ -568,8 +568,6 @@ function queryStyleUrl(context, selector, styleAttribute, customOptions) {
|
|
|
568
568
|
return null;
|
|
569
569
|
}
|
|
570
570
|
|
|
571
|
-
console.log('STYLE', styleAttribute, style);
|
|
572
|
-
|
|
573
571
|
const url = style.match(/url\(['"]?(.*)['"]?\)/)?.[1];
|
|
574
572
|
|
|
575
573
|
return url;
|
|
@@ -1053,6 +1051,7 @@ async function request(url, body, customOptions = {}, method = 'GET') {
|
|
|
1053
1051
|
ok: false,
|
|
1054
1052
|
status: res.status,
|
|
1055
1053
|
statusText: res.statusText,
|
|
1054
|
+
headers: res.headers,
|
|
1056
1055
|
response: res,
|
|
1057
1056
|
res,
|
|
1058
1057
|
};
|
|
@@ -1062,6 +1061,7 @@ async function request(url, body, customOptions = {}, method = 'GET') {
|
|
|
1062
1061
|
ok: true,
|
|
1063
1062
|
status: res.status,
|
|
1064
1063
|
statusText: res.statusText,
|
|
1064
|
+
headers: res.headers,
|
|
1065
1065
|
response: res,
|
|
1066
1066
|
res,
|
|
1067
1067
|
};
|
|
@@ -1072,7 +1072,7 @@ async function request(url, body, customOptions = {}, method = 'GET') {
|
|
|
1072
1072
|
statusText: res.statusText,
|
|
1073
1073
|
});
|
|
1074
1074
|
|
|
1075
|
-
if (res.headers['content-type']
|
|
1075
|
+
if (['application/json', 'application/javascript'].includes(res.headers['content-type']) && typeof res.data === 'object') {
|
|
1076
1076
|
return {
|
|
1077
1077
|
...base,
|
|
1078
1078
|
data: res.data,
|