fix js errors
This commit is contained in:
parent
9758476685
commit
68341bd8b8
7
dist/index.js
vendored
7
dist/index.js
vendored
@ -31123,8 +31123,7 @@ function gather_information(debug = false, output = false) {
|
||||
try {
|
||||
const stripTagPrefix = core.getInput("strip_tag_prefix");
|
||||
|
||||
if (debug) console.log(JSON.stringify(github.context));
|
||||
if (debug) console.log("github.context.ref=" + github.context.ref);
|
||||
if (debug) console.log(JSON.stringify(github.context, null, 2));
|
||||
|
||||
r.git_is_tag = github.context.ref.startsWith("refs/tags/");
|
||||
r.git_default_branch = github.context.payload?.repository?.defaultBranch;
|
||||
@ -31142,8 +31141,8 @@ function gather_information(debug = false, output = false) {
|
||||
r.git_is_branch = true;
|
||||
}
|
||||
|
||||
// gather regular branch info, also applies to tags
|
||||
if (r.git_is_tag || r.git_is_branch) {
|
||||
// gather regular branch info
|
||||
if (r.git_is_branch) {
|
||||
if (!github.context.ref.startsWith("refs/heads/")) {
|
||||
throw new Error(
|
||||
"Failed to determine branch for non-PR and non-Tag action",
|
||||
|
||||
Loading…
Reference in New Issue
Block a user