diff --git a/.github/workflows/close-featurebranch.yml b/.github/workflows/close-featurebranch.yml index e805cff0e0..5da3eb52cd 100644 --- a/.github/workflows/close-featurebranch.yml +++ b/.github/workflows/close-featurebranch.yml @@ -13,8 +13,8 @@ on: jobs: release: if: | - contains(github.event.pull_request.labels.*.name, 'feature-branch') || - github.event.label.name == 'feature-branch' + (github.event.action == 'closed' && contains(github.event.pull_request.labels.*.name, 'feature-branch')) || + github.event.label.name == 'feature-branch' runs-on: ubuntu-latest steps: - uses: actions/checkout@v3