forked from mirrors/action-gh-release
Only catch github API error (#32)
* move assignements out of try block * include compiled code
This commit is contained in:
parent
37ae175992
commit
d651ef48cb
2 changed files with 12 additions and 12 deletions
|
@ -97,13 +97,13 @@ exports.release = (config, releaser) => __awaiter(void 0, void 0, void 0, functi
|
|||
}
|
||||
catch (error) {
|
||||
if (error.status === 404) {
|
||||
const tag_name = tag;
|
||||
const name = config.input_name || tag;
|
||||
const body = util_1.releaseBody(config);
|
||||
const draft = config.input_draft;
|
||||
const prerelease = config.input_prerelease;
|
||||
console.log(`👩🏭 Creating new GitHub release for tag ${tag_name}...`);
|
||||
try {
|
||||
const tag_name = tag;
|
||||
const name = config.input_name || tag;
|
||||
const body = util_1.releaseBody(config);
|
||||
const draft = config.input_draft;
|
||||
const prerelease = config.input_prerelease;
|
||||
console.log(`👩🏭 Creating new GitHub release for tag ${tag_name}...`);
|
||||
let release = yield releaser.createRelease({
|
||||
owner,
|
||||
repo,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue