@nest-omni/core 1.0.46 → 1.0.48

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.
@@ -26,7 +26,7 @@ function getOmniAuthData(request, key) {
26
26
  };
27
27
  }
28
28
  else {
29
- console.error('User information is not transparently transmitted through the gateway: ' +
29
+ console.debug('User information is not transparently transmitted through the gateway: ' +
30
30
  JSON.stringify(headers));
31
31
  }
32
32
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nest-omni/core",
3
- "version": "1.0.46",
3
+ "version": "1.0.48",
4
4
  "description": "framework",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -55,6 +55,7 @@ class ContextProvider {
55
55
  static getAuthUser() {
56
56
  const auth = ContextProvider.get(ContextProvider.authUserKey);
57
57
  if (!auth) {
58
+ console.error(new Error().stack);
58
59
  throw new common_1.BadGatewayException('User information not found.');
59
60
  }
60
61
  return auth;
@@ -104,7 +104,6 @@ let ApiConfigService = ApiConfigService_1 = class ApiConfigService {
104
104
  return {
105
105
  autoLoadEntities: true,
106
106
  keepConnectionAlive: !this.isDev,
107
- dropSchema: this.isTest ? this.getBoolean('DB_DROP_SCHEMA') : false,
108
107
  type: 'mysql',
109
108
  host: this.getString('DB_HOST'),
110
109
  port: this.getNumber('DB_PORT'),
@@ -253,13 +252,11 @@ let ApiConfigService = ApiConfigService_1 = class ApiConfigService {
253
252
  transport,
254
253
  level: this.isDev ? 'debug' : 'info',
255
254
  customLogLevel: function (res) {
256
- if (res.statusCode < 300) {
257
- return 'info';
258
- }
259
- else if (res.statusCode >= 300 && res.statusCode < 500) {
255
+ if (res.statusCode >= 500)
256
+ return 'error';
257
+ if (res.statusCode >= 400)
260
258
  return 'warn';
261
- }
262
- return 'error';
259
+ return 'info';
263
260
  },
264
261
  wrapSerializers: true,
265
262
  customProps: (req, res) => {