Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update
@octokit/webhooks
to v9 (#1559)
BREAKING CHANGE: remove '*' event BREAKING CHANGE: app.webhooks.middleware has been removed in `@octokit/webhooks` v9 BREAKING CHANGE: removes the `webhookPath` option on `new Probot({})` for the webhooks middleware Co-authored-by: wolfy1339 <webmaster@wolfy1339.com>
- Loading branch information
Showing
21 changed files
with
970 additions
and
1,152 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,16 @@ | ||
import { RequestListener } from "http"; | ||
import { createNodeMiddleware as createWebbhooksMiddleware } from "@octokit/webhooks"; | ||
|
||
import { ApplicationFunction } from "./types"; | ||
import { MiddlewareOptions } from "./types"; | ||
|
||
export function createNodeMiddleware( | ||
appFn: ApplicationFunction, | ||
{ probot }: MiddlewareOptions | ||
{ probot, webhooksPath }: MiddlewareOptions | ||
): RequestListener { | ||
probot.load(appFn); | ||
|
||
return probot.webhooks.middleware; | ||
return createWebbhooksMiddleware(probot.webhooks, { | ||
path: webhooksPath || "/", | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.