From 4ebe9340bf103abf6807238d13fdb773aa1ee273 Mon Sep 17 00:00:00 2001 From: Jillian Tullo Date: Fri, 27 Jul 2018 08:53:15 -0400 Subject: [PATCH 1/2] encode path for VPN connection requests Ensures paths are properly encoded in the event they contain spaces or special characters --- packages/spaces/lib/vpn-connections.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/spaces/lib/vpn-connections.js b/packages/spaces/lib/vpn-connections.js index 49af3eff08..2b214c8087 100644 --- a/packages/spaces/lib/vpn-connections.js +++ b/packages/spaces/lib/vpn-connections.js @@ -30,7 +30,7 @@ module.exports = function (heroku) { function request (method, path, body) { return heroku.request({ method: method, - path: path, + path: encodeURI(path), body: body }) } From b55bcb22742cce76af30a69ee8bc468e4a99641b Mon Sep 17 00:00:00 2001 From: Jillian Tullo Date: Fri, 27 Jul 2018 08:53:48 -0400 Subject: [PATCH 2/2] remove reference to deleteVPN that has been previously removed --- packages/spaces/lib/vpn-connections.js | 6 ------ 1 file changed, 6 deletions(-) diff --git a/packages/spaces/lib/vpn-connections.js b/packages/spaces/lib/vpn-connections.js index 2b214c8087..9f32e5b06e 100644 --- a/packages/spaces/lib/vpn-connections.js +++ b/packages/spaces/lib/vpn-connections.js @@ -18,12 +18,6 @@ module.exports = function (heroku) { } function deleteVPNConnection (space, name) { - let lib = require('../lib/vpn')(heroku) - - if (!name) { - return lib.deleteVPN(space) - } - return request('DELETE', `/spaces/${space}/vpn-connections/${name}`) }