Skip to content

Commit

Permalink
Fix Issue Comment Error (#72)
Browse files Browse the repository at this point in the history
Co-authored-by: MrDogeBro <MrDogeBro@users.noreply.github.com>
Co-authored-by: Alex Page <alex@alexpage.com.au>
  • Loading branch information
3 people committed Jul 13, 2021
1 parent 0e9495c commit bb266ff
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
automate-project-columns:
runs-on: ubuntu-latest
steps:
- uses: alex-page/github-project-automation-plus@v0.8.0
- uses: alex-page/github-project-automation-plus@v0.8.1
with:
project: Backlog
column: Triage
Expand All @@ -51,7 +51,7 @@ jobs:
automate-project-columns:
runs-on: ubuntu-latest
steps:
- uses: alex-page/github-project-automation-plus@v0.8.0
- uses: alex-page/github-project-automation-plus@v0.8.1
with:
project: Backlog
column: To do
Expand Down Expand Up @@ -112,11 +112,12 @@ You may need to enable policy settings to allow running workflows from forks. Pl

## Release History

- v0.8.1 - Fix `issue_coment` error with automation
- v0.8.0 - Add new action type `add`
- v0.7.1 - Move Node.js version back to v12
- v0.7.0 - Update documentation and dependencies
- v0.6.0 - Add support for `pull_request_target` and `pull_request_review`
- v0.5.1 - Fix get event data from issue_coment
- v0.5.1 - Fix get event data from `issue_coment`
- v0.5.0 - Add option to `delete` card
- v0.4.0 - Add `issue_comment` event
- v0.3.0 - Add `pull_request_target` event
Expand Down
4 changes: 2 additions & 2 deletions dist/index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "github-project-automation-plus",
"version": "0.8.0",
"version": "0.8.1",
"description": "🤖 Automate GitHub Project cards with any webhook event",
"private": true,
"main": "dist/index.js",
Expand Down
9 changes: 4 additions & 5 deletions src/generate-project-query.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
* @param {string} eventName - The current event name
* @param {string} project - The project to find
*/
const projectQuery = (url, eventName, project) => (
`query {
const projectQuery = (url, eventName, project) =>
`query {
resource( url: "${url}" ) {
... on ${eventName === 'issues' ? 'Issue' : 'PullRequest'} {
... on ${eventName.startsWith('issue') ? 'Issue' : 'PullRequest'} {
projectCards {
nodes {
id
Expand Down Expand Up @@ -51,7 +51,6 @@ const projectQuery = (url, eventName, project) => (
}
}
}
}`
);
}`;

module.exports = projectQuery;

0 comments on commit bb266ff

Please sign in to comment.