@sanity/export 2.30.2-shopify.0 → 2.30.3-code-freeze-2022-05-13.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/lib/AssetHandler.js +1 -1
- package/package.json +2 -2
- package/src/AssetHandler.js +1 -1
package/lib/AssetHandler.js
CHANGED
|
@@ -229,7 +229,7 @@ class AssetHandler {
|
|
|
229
229
|
var isImage = assetDoc._type === 'sanity.imageAsset';
|
|
230
230
|
var url = parseUrl(assetDoc.url, true);
|
|
231
231
|
|
|
232
|
-
if (isImage && ['cdn.sanity.io', 'cdn.sanity.work'].includes(url.hostname)) {
|
|
232
|
+
if (isImage && ['cdn.sanity.io', 'cdn.sanity.work'].includes(url.hostname) && token) {
|
|
233
233
|
headers.Authorization = "Bearer ".concat(token);
|
|
234
234
|
url.query = _objectSpread(_objectSpread({}, url.query || {}), {}, {
|
|
235
235
|
dlRaw: 'true'
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sanity/export",
|
|
3
|
-
"version": "2.30.
|
|
3
|
+
"version": "2.30.3-code-freeze-2022-05-13.4+6cb6a80f94",
|
|
4
4
|
"description": "Export Sanity documents and assets",
|
|
5
5
|
"main": "lib/export.js",
|
|
6
6
|
"engines": {
|
|
@@ -49,5 +49,5 @@
|
|
|
49
49
|
"url": "https://github.com/sanity-io/sanity/issues"
|
|
50
50
|
},
|
|
51
51
|
"homepage": "https://www.sanity.io/",
|
|
52
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "6cb6a80f94cd7e93b21cedd4cadea7c43b0c6d6a"
|
|
53
53
|
}
|
package/src/AssetHandler.js
CHANGED
|
@@ -124,7 +124,7 @@ class AssetHandler {
|
|
|
124
124
|
const isImage = assetDoc._type === 'sanity.imageAsset'
|
|
125
125
|
|
|
126
126
|
const url = parseUrl(assetDoc.url, true)
|
|
127
|
-
if (isImage && ['cdn.sanity.io', 'cdn.sanity.work'].includes(url.hostname)) {
|
|
127
|
+
if (isImage && ['cdn.sanity.io', 'cdn.sanity.work'].includes(url.hostname) && token) {
|
|
128
128
|
headers.Authorization = `Bearer ${token}`
|
|
129
129
|
url.query = {...(url.query || {}), dlRaw: 'true'}
|
|
130
130
|
}
|