Upgrade octokit to v4.1.2
This commit is contained in:
parent
dbbcbe019d
commit
c1745a9831
1214 changed files with 160765 additions and 0 deletions
27
node_modules/@octokit/webhooks/dist-src/event-handler/index.js
generated
vendored
Normal file
27
node_modules/@octokit/webhooks/dist-src/event-handler/index.js
generated
vendored
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
import { createLogger } from "../createLogger.js";
|
||||
import {
|
||||
receiverOn as on,
|
||||
receiverOnAny as onAny,
|
||||
receiverOnError as onError
|
||||
} from "./on.js";
|
||||
import { receiverHandle as receive } from "./receive.js";
|
||||
import { removeListener } from "./remove-listener.js";
|
||||
function createEventHandler(options) {
|
||||
const state = {
|
||||
hooks: {},
|
||||
log: createLogger(options && options.log)
|
||||
};
|
||||
if (options && options.transform) {
|
||||
state.transform = options.transform;
|
||||
}
|
||||
return {
|
||||
on: on.bind(null, state),
|
||||
onAny: onAny.bind(null, state),
|
||||
onError: onError.bind(null, state),
|
||||
removeListener: removeListener.bind(null, state),
|
||||
receive: receive.bind(null, state)
|
||||
};
|
||||
}
|
||||
export {
|
||||
createEventHandler
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue