Skip to content

Commit 8807d2d

Browse files
rexxarsbjoerge
authored andcommitted
[client] Use URI-parameter for asset requests (#167)
1 parent 37b8951 commit 8807d2d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/@sanity/client/src/assets/assetsClient.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ assign(AssetsClient.prototype, {
3636
const observable = this.client._requestObservable({
3737
method: 'POST',
3838
timeout: options.timeout || 0,
39-
url: `/assets/${assetEndpoint}/${dataset}`,
39+
uri: `/assets/${assetEndpoint}/${dataset}`,
4040
headers: options.contentType ? {'Content-Type': options.contentType} : {},
4141
query,
4242
body
@@ -64,7 +64,7 @@ assign(AssetsClient.prototype, {
6464
const assetEndpoint = assetType === 'image' ? 'images' : 'files'
6565
return this.client.request({
6666
method: 'DELETE',
67-
url: `/assets/${assetEndpoint}/${dataset}/${docId}`
67+
uri: `/assets/${assetEndpoint}/${dataset}/${docId}`
6868
})
6969
},
7070

0 commit comments

Comments
 (0)