mirror of
https://github.com/softprops/action-gh-release.git
synced 2025-05-10 10:44:19 +00:00
Search for existing draft releases by name, not by tag
The tag is typically (or maybe even always) empty for the draft releases and can't be really used, while the release name will normally be unique, so use it as the key.
This commit is contained in:
parent
bdee2a89b1
commit
9414f126fb
2 changed files with 4 additions and 2 deletions
2
dist/index.js
vendored
2
dist/index.js
vendored
File diff suppressed because one or more lines are too long
|
@ -206,7 +206,9 @@ export const release = async (
|
||||||
owner,
|
owner,
|
||||||
repo,
|
repo,
|
||||||
})) {
|
})) {
|
||||||
let release = response.data.find((release) => release.tag_name === tag);
|
let release = response.data.find(
|
||||||
|
(release) => release.name === config.input_name
|
||||||
|
);
|
||||||
if (release) {
|
if (release) {
|
||||||
return release;
|
return release;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue