hfs 0.49.2 → 0.49.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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hfs",
3
- "version": "0.49.2",
3
+ "version": "0.49.3",
4
4
  "description": "HTTP File Server",
5
5
  "keywords": [
6
6
  "file server",
@@ -15,7 +15,7 @@
15
15
  "watch-server-proxied": "cross-env FRONTEND_PROXY=3005 ADMIN_PROXY=3006 npm run watch-server",
16
16
  "start-frontend": "npm run start --workspace=frontend",
17
17
  "start-admin": "npm run start --workspace=admin",
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",
18
+ "build-all": "npm audit --omit=dev --audit-level=high && rm -rf dist && npm i && npm run build-server && npm run build-frontend && npm run build-admin && echo COMPLETED",
19
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",
package/src/config.js CHANGED
@@ -89,7 +89,7 @@ function defineConfig(k, defaultValue, compiler) {
89
89
  else
90
90
  setConfig1(k, v);
91
91
  },
92
- compiled: () => compiled !== null && compiled !== void 0 ? compiled : (0, misc_1.throw_)("missing compiler"),
92
+ compiled: () => (compiler ? compiled : (0, misc_1.throw_)("missing compiler")),
93
93
  };
94
94
  if (compiler)
95
95
  ret.sub((...args) => compiled = compiler(...args));
package/src/const.js CHANGED
@@ -42,7 +42,7 @@ exports.DEV = process.env.DEV || exports.argv.dev ? 'DEV' : '';
42
42
  exports.ORIGINAL_CWD = process.cwd();
43
43
  exports.HFS_STARTED = new Date();
44
44
  const PKG_PATH = (0, path_1.join)(__dirname, '..', 'package.json');
45
- exports.BUILD_TIMESTAMP = "2023-11-06T09:23:00.007Z";
45
+ exports.BUILD_TIMESTAMP = "2023-11-25T23:47:21.912Z";
46
46
  const pkg = JSON.parse(fs.readFileSync(PKG_PATH, 'utf8'));
47
47
  exports.VERSION = pkg.version;
48
48
  exports.RUNNING_BETA = exports.VERSION.includes('-');
package/src/plugins.js CHANGED
@@ -250,7 +250,7 @@ const serverCode = (0, config_1.defineConfig)('server_code', '', async (script,
250
250
  }
251
251
  });
252
252
  let serverCodePlugin;
253
- serverCode.sub(() => serverCode.compiled().then(x => serverCodePlugin = x));
253
+ serverCode.sub(() => { var _a; return (_a = serverCode.compiled()) === null || _a === void 0 ? void 0 : _a.then(x => serverCodePlugin = x); });
254
254
  function mapPlugins(cb, includeServerCode = true) {
255
255
  const entries = Object.entries(plugins);
256
256
  return entries.map(([plName, pl]) => {