mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
🐛 Fix bug with activating some trigger nodes #1715
This commit is contained in:
@@ -353,7 +353,7 @@ export class GithubTrigger implements INodeType {
|
||||
try {
|
||||
await githubApiRequest.call(this, 'GET', endpoint, {});
|
||||
} catch (error) {
|
||||
if (error.message.includes('[404]:')) {
|
||||
if (error.httpCode === '404') {
|
||||
// Webhook does not exist
|
||||
delete webhookData.webhookId;
|
||||
delete webhookData.webhookEvents;
|
||||
@@ -399,7 +399,7 @@ export class GithubTrigger implements INodeType {
|
||||
try {
|
||||
responseData = await githubApiRequest.call(this, 'POST', endpoint, body);
|
||||
} catch (error) {
|
||||
if (error.message.includes('[422]:')) {
|
||||
if (error.httpCode === '422') {
|
||||
// Webhook exists already
|
||||
|
||||
// Get the data of the already registered webhook
|
||||
|
||||
Reference in New Issue
Block a user