@imqueue/async-logger 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -14,20 +14,20 @@ There are two actual ways of using async logger.
14
14
 
15
15
  1. Rely on singleton instance produced by this library, which is configured by
16
16
  environment variables (see Configuration section below)
17
-
17
+
18
18
  In this case as simple as
19
19
  ~~~typescript
20
- import logger from '@imqueue/async-async-logger';
21
-
20
+ import logger from '@imqueue/async-logger';
21
+
22
22
  serviceOptions.logger = logger;
23
23
  ~~~
24
24
 
25
25
  2. Instantiate and configure async logger programmatically:
26
26
  ~~~typescript
27
- import { Logger } from '@imqueue/async-async-logger';
28
-
27
+ import { Logger } from '@imqueue/async-logger';
28
+
29
29
  const { name, version } = require('./package.json');
30
-
30
+
31
31
  const logger = new Logger({
32
32
  transports: [{
33
33
  type: 'http',
@@ -48,7 +48,7 @@ There are two actual ways of using async logger.
48
48
  hostname: 'localhost'
49
49
  },
50
50
  });
51
-
51
+
52
52
  serviceOptions.logger = logger;
53
53
  ~~~
54
54
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@imqueue/async-logger",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "description": "Configurable async logger over winston for @imqueue services",
5
5
  "keywords": [
6
6
  "logger",
package/src/Logger.js CHANGED
@@ -109,8 +109,8 @@ exports.Logger = Logger;
109
109
  */
110
110
  Logger.console = {
111
111
  log: (...args) => setTimeout(() => console.log(...args)),
112
- info: (...args) => setTimeout(() => console.log(...args)),
113
- warn: (...args) => setTimeout(() => console.log(...args)),
114
- error: (...args) => setTimeout(() => console.log(...args)),
112
+ info: (...args) => setTimeout(() => console.info(...args)),
113
+ warn: (...args) => setTimeout(() => console.warn(...args)),
114
+ error: (...args) => setTimeout(() => console.error(...args)),
115
115
  };
116
116
  //# sourceMappingURL=Logger.js.map