Skip to content

Commit

Permalink
feat:protected methods to access in child class
Browse files Browse the repository at this point in the history
  • Loading branch information
bmeverett authored and iamolegga committed Apr 26, 2023
1 parent d8584ec commit 52232ae
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/PinoLogger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ export class PinoLogger implements PinoMethods {
*/
static readonly root: pino.Logger;

private context = '';
private readonly contextName: string;
protected context = '';
protected readonly contextName: string;

constructor(
@Inject(PARAMS_PROVIDER_TOKEN) { pinoHttp, renameContext }: Params,
Expand Down Expand Up @@ -108,7 +108,7 @@ export class PinoLogger implements PinoMethods {
this.context = value;
}

private call(method: pino.Level, ...args: Parameters<LoggerFn>) {
protected call(method: pino.Level, ...args: Parameters<LoggerFn>) {
if (this.context) {
if (isFirstArgObject(args)) {
const firstArg = args[0];
Expand Down

0 comments on commit 52232ae

Please sign in to comment.