From 1c8c9a76158ac02fec2d670c3deb0dca37650714 Mon Sep 17 00:00:00 2001 From: Ashcon Partovi Date: Wed, 1 Mar 2023 16:49:16 -0800 Subject: [PATCH] Fix encoding bug with 'action:' version --- dist/setup.js | 2 +- src/setup.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/setup.js b/dist/setup.js index 0a2d5af..f7256c4 100644 --- a/dist/setup.js +++ b/dist/setup.js @@ -59,7 +59,7 @@ function getDownloadUrl(options) { cacheKey: null, }; } - const release = options?.version ?? "latest"; + const release = encodeURIComponent(options?.version ?? "latest"); const os = options?.os ?? process.platform; const arch = options?.arch ?? process.arch; const avx2 = options?.avx2 ?? true; diff --git a/src/setup.ts b/src/setup.ts index 1d760d7..d475963 100644 --- a/src/setup.ts +++ b/src/setup.ts @@ -79,7 +79,7 @@ function getDownloadUrl(options?: { cacheKey: null, }; } - const release = options?.version ?? "latest"; + const release = encodeURIComponent(options?.version ?? "latest"); const os = options?.os ?? process.platform; const arch = options?.arch ?? process.arch; const avx2 = options?.avx2 ?? true;