Skip to content

Commit

Permalink
dont bother with log levels in yargs right now, messy
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisbenincasa committed Apr 2, 2024
1 parent 11b527b commit 970f5c9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion server/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,4 +161,4 @@ ${chalk.blue(' |_| ')}${chalk.green(' \\___/')}${chalk.yellow(
},
)
.help()
.parse();
.parseAsync();
3 changes: 1 addition & 2 deletions server/src/logger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import chalk from 'chalk';
import { isUndefined, join } from 'lodash-es';
import { dirname } from 'node:path';
import { fileURLToPath } from 'node:url';
import { globalOptions } from './globals.js';
import { isProduction } from './util.js';

const __filename = fileURLToPath(import.meta.url);
Expand Down Expand Up @@ -46,7 +45,7 @@ const hformat = (module: ImportMeta) => {

const createLogger = (module: ImportMeta) => {
const logger = winston.createLogger({
level: globalOptions().log_level,
level: process.env.LOG_LEVEL ?? (isProduction ? 'info' : 'debug'),
format: winston.format.combine(
winston.format.splat(),
winston.format.timestamp(),
Expand Down

0 comments on commit 970f5c9

Please sign in to comment.