hfs 0.48.2 → 0.48.3
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/package.json +3 -3
- package/src/api.net.js +2 -2
- package/src/const.js +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hfs",
|
|
3
|
-
"version": "0.48.
|
|
3
|
+
"version": "0.48.3",
|
|
4
4
|
"description": "HTTP File Server",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"file server",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"start-frontend": "npm run start --workspace=frontend",
|
|
17
17
|
"start-admin": "npm run start --workspace=admin",
|
|
18
18
|
"build-all": "npm audit --omit=dev && rm -rf dist && npm i && npm run build-server && npm run build-frontend && npm run build-admin && echo COMPLETED",
|
|
19
|
-
"build-server": "rm -rf dist/src dist/plugins && tsc --target es2018 && touch package.json && cp -v -r package.json README* LICENSE* plugins dist && find dist -name .DS_Store -delete && node afterbuild.js",
|
|
19
|
+
"build-server": "rm -rf dist/src dist/plugins && tsc --target es2018 && touch package.json && cp -v -r package.json central.json README* LICENSE* plugins dist && find dist -name .DS_Store -delete && node afterbuild.js",
|
|
20
20
|
"build-frontend": "npm run build --workspace=frontend",
|
|
21
21
|
"build-admin": "npm run build --workspace=admin",
|
|
22
22
|
"server-for-test": "node dist/src --cwd . --config tests && rm custom.html",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"limiter": "^2.1.0",
|
|
79
79
|
"lodash": "^4.17.21",
|
|
80
80
|
"minimist": "^1.2.6",
|
|
81
|
-
"nat-upnp": "
|
|
81
|
+
"nat-upnp-ts": "^2.0.1",
|
|
82
82
|
"node-html-parser": "^6.1.5",
|
|
83
83
|
"open": "^8.4.0",
|
|
84
84
|
"tssrp6a": "^3.0.0",
|
package/src/api.net.js
CHANGED
|
@@ -6,7 +6,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
7
|
exports.acmeMiddleware = exports.externalIp = void 0;
|
|
8
8
|
const apiMiddleware_1 = require("./apiMiddleware");
|
|
9
|
-
const
|
|
9
|
+
const nat_upnp_ts_1 = require("nat-upnp-ts");
|
|
10
10
|
const const_1 = require("./const");
|
|
11
11
|
const axios_1 = __importDefault(require("axios"));
|
|
12
12
|
const node_html_parser_1 = require("node-html-parser");
|
|
@@ -20,7 +20,7 @@ const acme_client_1 = __importDefault(require("acme-client"));
|
|
|
20
20
|
const promises_1 = __importDefault(require("fs/promises"));
|
|
21
21
|
const http_1 = require("http");
|
|
22
22
|
const promises_2 = require("dns/promises");
|
|
23
|
-
const client = new
|
|
23
|
+
const client = new nat_upnp_ts_1.Client({ timeout: 4000 });
|
|
24
24
|
const originalMethod = client.getGateway;
|
|
25
25
|
// other client methods call getGateway too, so this will ensure they reuse this same result
|
|
26
26
|
client.getGateway = (0, misc_1.debounceAsync)(() => originalMethod.apply(client), 0, { retain: misc_1.HOUR, retainFailure: 30000 });
|
package/src/const.js
CHANGED
|
@@ -38,7 +38,7 @@ exports.DEV = process.env.DEV || exports.argv.dev ? 'DEV' : '';
|
|
|
38
38
|
exports.ORIGINAL_CWD = process.cwd();
|
|
39
39
|
exports.HFS_STARTED = new Date();
|
|
40
40
|
const PKG_PATH = (0, path_1.join)(__dirname, '..', 'package.json');
|
|
41
|
-
exports.BUILD_TIMESTAMP = "2023-09-
|
|
41
|
+
exports.BUILD_TIMESTAMP = "2023-09-21T14:29:22.907Z";
|
|
42
42
|
const pkg = JSON.parse(fs.readFileSync(PKG_PATH, 'utf8'));
|
|
43
43
|
exports.VERSION = pkg.version;
|
|
44
44
|
exports.RUNNING_BETA = exports.VERSION.includes('-');
|