Skip to content
This repository has been archived by the owner on Oct 9, 2022. It is now read-only.

Commit

Permalink
fix: debug statements and default values
Browse files Browse the repository at this point in the history
  • Loading branch information
kdev committed Jun 28, 2022
1 parent 4e78c44 commit e5fa426
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This template includes tests, linting, a validation workflow, publishing, and ve
## Usage

```yaml
uses: LEDBrain/[email protected].2
uses: LEDBrain/[email protected].3
with:
# Optional: branch to lift the restriction on; defaults to the current branch
branch: main
Expand Down
6 changes: 3 additions & 3 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ async function run() {
(t) => t?.slug
) || [],
}
: null,
: undefined,
dismiss_stale_reviews:
initState.required_pull_request_reviews
?.dismiss_stale_reviews || false,
Expand All @@ -125,7 +125,7 @@ async function run() {
(a) => a?.slug
) || [],
}
: null,
: undefined,
},

required_signatures:
Expand Down Expand Up @@ -167,7 +167,7 @@ async function run() {
core.debug(updatedState.data);
}
} catch (error) {
if (error.code === 404 && error.message === 'Branch not protected') {
if (error.status === 404 && error.message === 'Branch not protected') {
core.notice('Branch not protected');
core.saveState('STATE_branch-protection-has-run', null);
} else {
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "branch-protection-action",
"version": "1.0.2",
"version": "1.0.3",
"description": "A tool to remove branch protection for a workflow run",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit e5fa426

Please sign in to comment.