From cf1a5bf7487f084d9562e0b041562f8aecfdee22 Mon Sep 17 00:00:00 2001 From: Bowden Date: Mon, 12 Mar 2018 09:43:29 -0700 Subject: [PATCH] fixed some imports --- src/util/logger.ts | 5 +++-- src/util/secrets.ts | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/util/logger.ts b/src/util/logger.ts index 4004e6e..cb052af 100644 --- a/src/util/logger.ts +++ b/src/util/logger.ts @@ -1,7 +1,8 @@ -import * as winston from "winston"; +import winston from "winston"; +import { Logger } from "winston"; import { ENVIRONMENT } from "./secrets"; -const logger = new (winston.Logger)({ +const logger = new (Logger)({ transports: [ new (winston.transports.Console)({ level: process.env.NODE_ENV === "production" ? "error" : "debug" }), new (winston.transports.File)({ filename: "debug.log", level: "debug"}) diff --git a/src/util/secrets.ts b/src/util/secrets.ts index bc6d27a..4fbf6b5 100644 --- a/src/util/secrets.ts +++ b/src/util/secrets.ts @@ -1,6 +1,6 @@ import logger from "./logger"; -import * as dotenv from "dotenv"; -import * as fs from "fs"; +import dotenv from "dotenv"; +import fs from "fs"; if (fs.existsSync(".env")) { logger.debug("Using .env file to supply config environment variables");