mirror of
https://github.com/verdaccio/verdaccio.git
synced 2024-11-13 03:35:52 +01:00
chore: encode parts of URL (#4922)
This commit is contained in:
parent
fa22fa340d
commit
e3c55f008c
5
.changeset/rude-birds-design.md
Normal file
5
.changeset/rude-birds-design.md
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
'verdaccio': patch
|
||||
---
|
||||
|
||||
chore: encode parts of URL
|
@ -216,7 +216,7 @@ export class ServerQuery {
|
||||
*/
|
||||
public removePackage(name: string, rev) {
|
||||
return this.request({
|
||||
uri: `/${encodeURIComponent(name)}/-rev/${rev}`,
|
||||
uri: `/${encodeURIComponent(name)}/-rev/${encodeURIComponent(rev)}`,
|
||||
method: 'DELETE',
|
||||
headers: {
|
||||
[HEADERS.CONTENT_TYPE]: HEADERS.JSON_CHARSET,
|
||||
@ -226,7 +226,7 @@ export class ServerQuery {
|
||||
|
||||
public removeSingleTarball(name: string, filename: string) {
|
||||
return this.request({
|
||||
uri: `/${encodeURIComponent(name)}/-/${filename}/-rev/whatever`,
|
||||
uri: `/${encodeURIComponent(name)}/-/${encodeURIComponent(filename)}/-rev/whatever`,
|
||||
method: 'DELETE',
|
||||
headers: {
|
||||
[HEADERS.CONTENT_TYPE]: HEADERS.JSON_CHARSET,
|
||||
|
Loading…
Reference in New Issue
Block a user