Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(Github Trigger Node): fix issue with trigger not always activating #4284

Merged
merged 1 commit into from
Oct 7, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/nodes-base/nodes/Github/GithubTrigger.node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ export class GithubTrigger implements INodeType {
try {
await githubApiRequest.call(this, 'GET', endpoint, {});
} catch (error) {
if (error.httpCode === '404') {
if (error.cause.httpCode === '404') {
// Webhook does not exist
delete webhookData.webhookId;
delete webhookData.webhookEvents;
Expand Down Expand Up @@ -412,7 +412,7 @@ export class GithubTrigger implements INodeType {
try {
responseData = await githubApiRequest.call(this, 'POST', endpoint, body);
} catch (error) {
if (error.httpCode === '422') {
if (error.cause.httpCode === '422') {
// Webhook exists already

// Get the data of the already registered webhook
Expand Down