Skip to content

Commit

Permalink
fix linter of separate webhook handler example
Browse files Browse the repository at this point in the history
  • Loading branch information
freisenhauer committed Nov 22, 2024
1 parent 534ce88 commit a3ca001
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions packages/mitthooks/src/examples/separateWebhookHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,19 +52,22 @@ function createCustomSeparateWebhookHandler(
.build();
}

// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-unused-vars
function createCustomSeparateWebhookHandlerWithHandlerForAdded(
extensionStorage: ExtensionStorage,
extensionId: string,
): SeparateWebhookHandlers {
const handlers = new SeparateWebhookHandlerFactory(extensionStorage, extensionId).build();

handlers.ExtensionAddedToContext = WebhookHandlerChain
const extendedChain = WebhookHandlerChain
.fromHandlerFunctions(
handlers.ExtensionAddedToContext,
async (webhookContent) => {
() => {
console.log("This is only gonna be called for ExtensionAddedToContext");
},
).handleWebhook;
)

handlers.ExtensionAddedToContext = extendedChain.handleWebhook.bind(extendedChain);

return handlers;
}

0 comments on commit a3ca001

Please sign in to comment.