From 248abfdbe9d9016db814ad1dc16038f8317e336e Mon Sep 17 00:00:00 2001 From: Henrik Poulsen Date: Tue, 11 Jan 2022 14:34:27 +0100 Subject: [PATCH] Return undefined if GHES_TOKEN is not set when running on GHES --- src/install-python.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/install-python.ts b/src/install-python.ts index 7aee61d55..44e9fa3b2 100644 --- a/src/install-python.ts +++ b/src/install-python.ts @@ -8,7 +8,9 @@ import {IS_WINDOWS, IS_LINUX, isGhes} from './utils'; const TOKEN = core.getInput('token'); const GHES_TOKEN = core.getInput('ghes_token'); const AUTH = isGhes() - ? `token ${GHES_TOKEN}` + ? GHES_TOKEN + ? `token ${GHES_TOKEN}` + : undefined : TOKEN ? `token ${TOKEN}` : undefined;