Skip to content

Commit

Permalink
fix: derive Server log from Probot log (#1924)
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfy1339 committed Nov 18, 2023
1 parent cba19e2 commit 122740b
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/server/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import { join } from "path";
import type { Logger } from "pino";
import { createNodeMiddleware as createWebhooksMiddleware } from "@octokit/webhooks";

import { getLog } from "../helpers/get-log";
import { getLoggingMiddleware } from "./logging-middleware";
import { createWebhookProxy } from "../helpers/webhook-proxy";
import { VERSION } from "../version";
Expand Down Expand Up @@ -38,10 +37,10 @@ export class Server {

constructor(options: ServerOptions = {} as ServerOptions) {
this.expressApp = express();
this.log = options.log || getLog().child({ name: "server" });
this.probotApp = new options.Probot({
request: options.request,
});
this.log = options.log || this.probotApp.log.child({ name: "server" });

this.state = {
cwd: options.cwd || process.cwd(),
Expand Down

0 comments on commit 122740b

Please sign in to comment.