Skip to content

Commit

Permalink
Fix issue where logging will be stuck on info level
Browse files Browse the repository at this point in the history
  • Loading branch information
devinbinnie committed Sep 11, 2023
1 parent ce14475 commit a58b022
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/common/log.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ export const setLoggingLevel = (level: string) => {
log.transports.file.level = level as LevelOption;
};

// Start on info by default
setLoggingLevel('info');

export const getLevel = () => log.transports.file.level as string;

export class Logger {
private prefixes: string[];

constructor(...prefixes: string[]) {
this.prefixes = this.shortenPrefixes(...prefixes);

// Start on info by default
setLoggingLevel('info');
}

withPrefix = (...prefixes: string[]) => {
Expand Down

0 comments on commit a58b022

Please sign in to comment.