Skip to content

Commit

Permalink
Make package compatible with probot v10 (#46)
Browse files Browse the repository at this point in the history
  • Loading branch information
scolandrea authored Sep 17, 2020
1 parent 55ddd2c commit 345b245
Show file tree
Hide file tree
Showing 3 changed files with 2,477 additions and 1,865 deletions.
10 changes: 5 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
const { createProbot } = require('probot')
const { resolve } = require('probot/lib/resolver')
const { findPrivateKey } = require('probot/lib/private-key')
const { Probot } = require('probot')
const { resolve } = require('probot/lib/helpers/resolve-app-function')
const { findPrivateKey } = require('probot/lib/helpers/get-private-key')
const { template } = require('./views/probot')

let probot

const loadProbot = appFn => {
probot = probot || createProbot({
probot = probot || new Probot({
id: process.env.APP_ID,
secret: process.env.WEBHOOK_SECRET,
cert: findPrivateKey()
privateKey: findPrivateKey()
})

if (typeof appFn === 'string') {
Expand Down
Loading

0 comments on commit 345b245

Please sign in to comment.