mirror of
https://git.stamm.me/OpenServer/NodeLogging.git
synced 2024-11-25 09:09:24 +00:00
Fixing wrong filename change on custom Logger
This commit is contained in:
parent
e973ab7e59
commit
88d045aa9c
@ -46,7 +46,7 @@ class LoggingBase {
|
|||||||
options.logfile = `./logs/all.${options.name}.log`;
|
options.logfile = `./logs/all.${options.name}.log`;
|
||||||
}
|
}
|
||||||
if (options.errorfile === undefined) {
|
if (options.errorfile === undefined) {
|
||||||
options.logfile = `./logs/error.${options.name}.log`;
|
options.errorfile = `./logs/error.${options.name}.log`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.config = Object.assign({
|
this.config = Object.assign({
|
||||||
|
File diff suppressed because one or more lines are too long
@ -17,4 +17,6 @@ index_1.Logging.waitForSetup().then(() => {
|
|||||||
index_1.Logging.log(crypto_1.randomBytes(50000).toString("hex"));
|
index_1.Logging.log(crypto_1.randomBytes(50000).toString("hex"));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
let cus = new index_1.LoggingBase({ name: "test" });
|
||||||
|
cus.log("Hello from custom Logger");
|
||||||
//# sourceMappingURL=test.js.map
|
//# sourceMappingURL=test.js.map
|
@ -1 +1 @@
|
|||||||
{"version":3,"file":"test.js","sourceRoot":"","sources":["../src/test.ts"],"names":[],"mappings":";;AAAA,mCAAkC;AAClC,mCAAqC;AAErC,eAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAA;AACnB,eAAO,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,EAAE,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,IAAI,CAAC,CAAC;AAC1C,eAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;AACvC,eAAO,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAAC;AAClC,eAAO,CAAC,YAAY,CAAC,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;AAE/C,eAAO,CAAC,GAAG,CAAC,gFAAgF,C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C5B,eAAO,CAAC,YAAY,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE;IAC9B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,EAAE,CAAC,EAAE,EAAE;QAC5B,eAAO,CAAC,GAAG,CAAC,oBAAW,CAAC,KAAK,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAA;KACjD;AACJ,CAAC,CAAC,CAAC;AACH,IAAI,GAAG,GAAG,IAAI,mBAAW,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC,CAAC;AAC5C,GAAG,CAAC,GAAG,CAAC,0BAA0B,CAAC,CAAA"}
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@hibas123/nodelogging",
|
"name": "@hibas123/nodelogging",
|
||||||
"version": "1.3.5",
|
"version": "1.3.6",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "out/index.js",
|
"main": "out/index.js",
|
||||||
"types": "out/index.d.ts",
|
"types": "out/index.d.ts",
|
||||||
|
@ -65,7 +65,7 @@ export class LoggingBase {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (options.errorfile === undefined) {
|
if (options.errorfile === undefined) {
|
||||||
options.logfile = `./logs/error.${options.name}.log`
|
options.errorfile = `./logs/error.${options.name}.log`
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
this.config = Object.assign(<LoggingBaseOptions>{
|
this.config = Object.assign(<LoggingBaseOptions>{
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Logging } from "./index";
|
import { Logging, LoggingBase } from "./index";
|
||||||
import { randomBytes } from "crypto";
|
import { randomBytes } from "crypto";
|
||||||
|
|
||||||
Logging.log("test")
|
Logging.log("test")
|
||||||
@ -16,4 +16,6 @@ Logging.waitForSetup().then(() => {
|
|||||||
for (let i = 0; i < 7000; i++) {
|
for (let i = 0; i < 7000; i++) {
|
||||||
Logging.log(randomBytes(50000).toString("hex"))
|
Logging.log(randomBytes(50000).toString("hex"))
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
let cus = new LoggingBase({ name: "test" });
|
||||||
|
cus.log("Hello from custom Logger")
|
Loading…
Reference in New Issue
Block a user