Cleanup some files and setting logEvel based on dev env
This commit is contained in:
parent
518d46f410
commit
62ef572fbf
@ -4,7 +4,6 @@ import getLevelDB from "../storage";
|
||||
import PathLock from "./lock";
|
||||
import Query from "./query";
|
||||
import { Observable } from "@hibas123/utils";
|
||||
import Logging from "@hibas123/logging";
|
||||
|
||||
export class DatabaseManager {
|
||||
static databases = new Map<string, Database>();
|
||||
|
@ -4,6 +4,9 @@ import config from "./config";
|
||||
import { DatabaseManager } from "./database/database";
|
||||
import { createServer } from "http";
|
||||
import { ConnectionManager } from "./connection";
|
||||
import { LoggingTypes } from "@hibas123/logging";
|
||||
|
||||
Logging.logLevel = config.dev ? LoggingTypes.Debug : LoggingTypes.Log;
|
||||
|
||||
DatabaseManager.init().then(() => {
|
||||
const http = createServer(Web.callback());
|
||||
|
@ -1,12 +1,10 @@
|
||||
import * as Router from "koa-router";
|
||||
import Settings from "../../settings";
|
||||
import getForm from "../helper/form";
|
||||
import Logging from "@hibas123/nodelogging";
|
||||
import getTable from "../helper/table";
|
||||
import { BadRequestError, NoPermissionError } from "../helper/errors";
|
||||
import { DatabaseManager } from "../../database/database";
|
||||
import { FieldEncoder } from "../../database/query";
|
||||
import getTemplate from "../helper/hb";
|
||||
import config from "../../config";
|
||||
|
||||
const AdminRoute = new Router();
|
||||
|
Reference in New Issue
Block a user