@midwayjs/express 3.0.0-beta.5 → 3.0.0-beta.6

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/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.0.0-beta.6](https://github.com/midwayjs/midway/compare/v3.0.0-beta.5...v3.0.0-beta.6) (2021-11-26)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * class transformer method missing ([#1387](https://github.com/midwayjs/midway/issues/1387)) ([074e839](https://github.com/midwayjs/midway/commit/074e8393598dc95e2742f735df75a2191c5fe25d))
12
+
13
+
14
+
15
+
16
+
6
17
  # [3.0.0-beta.5](https://github.com/midwayjs/midway/compare/v3.0.0-beta.4...v3.0.0-beta.5) (2021-11-25)
7
18
 
8
19
  **Note:** Version bump only for package @midwayjs/express
package/dist/framework.js CHANGED
@@ -31,6 +31,7 @@ let MidwayExpressFramework = class MidwayExpressFramework extends core_1.BaseFra
31
31
  });
32
32
  }
33
33
  async run() {
34
+ var _a;
34
35
  // use global middleware
35
36
  const globalMiddleware = await this.getMiddleware();
36
37
  this.app.use(globalMiddleware);
@@ -70,7 +71,8 @@ let MidwayExpressFramework = class MidwayExpressFramework extends core_1.BaseFra
70
71
  }
71
72
  // register httpServer to applicationContext
72
73
  this.applicationContext.registerObject(core_1.HTTP_SERVER_KEY, this.server);
73
- if (this.configurationOptions.port) {
74
+ const customPort = (_a = process.env.MIDWAY_HTTP_PORT) !== null && _a !== void 0 ? _a : this.configurationOptions.port;
75
+ if (customPort) {
74
76
  new Promise(resolve => {
75
77
  const args = [this.configurationOptions.port];
76
78
  if (this.configurationOptions.hostname) {
@@ -80,6 +82,7 @@ let MidwayExpressFramework = class MidwayExpressFramework extends core_1.BaseFra
80
82
  resolve();
81
83
  });
82
84
  this.server.listen(...args);
85
+ process.env.MIDWAY_HTTP_PORT = String(customPort);
83
86
  });
84
87
  }
85
88
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@midwayjs/express",
3
- "version": "3.0.0-beta.5",
3
+ "version": "3.0.0-beta.6",
4
4
  "description": "Midway Web Framework for Express",
5
5
  "main": "dist/index",
6
6
  "typings": "dist/index.d.ts",
@@ -23,14 +23,14 @@
23
23
  ],
24
24
  "license": "MIT",
25
25
  "devDependencies": {
26
- "@midwayjs/decorator": "^3.0.0-beta.5",
27
- "@midwayjs/mock": "^3.0.0-beta.5",
26
+ "@midwayjs/decorator": "^3.0.0-beta.6",
27
+ "@midwayjs/mock": "^3.0.0-beta.6",
28
28
  "@types/express": "^4.17.8",
29
29
  "fs-extra": "^8.0.1"
30
30
  },
31
31
  "dependencies": {
32
- "@midwayjs/core": "^3.0.0-beta.5",
33
- "@midwayjs/logger": "^3.0.0-beta.5",
32
+ "@midwayjs/core": "^3.0.0-beta.6",
33
+ "@midwayjs/logger": "^3.0.0-beta.6",
34
34
  "express": "^4.17.1"
35
35
  },
36
36
  "author": "Harry Chen <czy88840616@gmail.com>",
@@ -41,5 +41,5 @@
41
41
  "engines": {
42
42
  "node": ">=12"
43
43
  },
44
- "gitHead": "ab0bf05ae6d13f6435db2f7223202be61d585a1b"
44
+ "gitHead": "e4595d30b369e36bef21b36f2b3737d8bc2f802d"
45
45
  }