Reworked auth again!
All checks were successful
Lint / pre-commit Linting (push) Successful in 25s

This commit is contained in:
Philipp Horstenkamp 2023-11-26 21:23:28 +01:00
parent a114309427
commit 7b50736f64
Signed by: Philipp
GPG Key ID: DD53EAC36AFB61B4

View File

@ -83,7 +83,6 @@ async function postCode() {
const token = core.getInput("token") || undefined; const token = core.getInput("token") || undefined;
const username = core.getInput("username") || undefined; const username = core.getInput("username") || undefined;
core.info(username);
const password = core.getInput("password") || undefined; const password = core.getInput("password") || undefined;
const prefix = core.getInput("source-prefix"); const prefix = core.getInput("source-prefix");
const pattern = core.getInput("pattern") || "*.js"; const pattern = core.getInput("pattern") || "*.js";
@ -102,7 +101,7 @@ async function postCode() {
hostname: hostname, hostname: hostname,
port: port, port: port,
path: path, path: path,
username: username, username: "NameVergessen",
password: password, password: password,
}; };
@ -121,7 +120,7 @@ async function postCode() {
} else { } else {
core.info(`Logging into as user ${username}`); core.info(`Logging into as user ${username}`);
const response = Promise.resolve() const response = Promise.resolve()
.then(() => api.auth("NameVergessen", password)) .then(() => api.auth(username, password))
.then(() => { .then(() => {
return api.code.set(branch, code); // Set the code on the specified branch return api.code.set(branch, code); // Set the code on the specified branch
}) })