@e-mc/core 0.13.3 → 0.13.5
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 +9 -9
- package/index.js +4 -2
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
|
|
10
10
|
## Interface
|
|
11
11
|
|
|
12
|
-
* [View Source](https://www.unpkg.com/@e-mc/types@0.13.
|
|
12
|
+
* [View Source](https://www.unpkg.com/@e-mc/types@0.13.5/lib/index.d.ts)
|
|
13
13
|
|
|
14
14
|
```typescript
|
|
15
15
|
import type { DataSource, LogStatus, WorkerAction } from "./squared";
|
|
@@ -74,7 +74,7 @@ interface HostConstructor extends ModuleConstructor {
|
|
|
74
74
|
getThreadCount(full: true): ThreadCountStat;
|
|
75
75
|
getThreadCount(username: string, iv?: BinaryLike): ThreadCountStat;
|
|
76
76
|
getThreadCount(username?: string | boolean, iv?: BinaryLike): number;
|
|
77
|
-
getPermissionFromSettings(): IPermission;
|
|
77
|
+
getPermissionFromSettings(freeze?: boolean): IPermission;
|
|
78
78
|
readonly prototype: IHost;
|
|
79
79
|
new(config?: HostInitConfig): IHost;
|
|
80
80
|
}
|
|
@@ -319,13 +319,13 @@ NOTE: **@e-mc/core** is mostly a collection of abstract base classes which canno
|
|
|
319
319
|
|
|
320
320
|
## References
|
|
321
321
|
|
|
322
|
-
- https://www.unpkg.com/@e-mc/types@0.13.
|
|
323
|
-
- https://www.unpkg.com/@e-mc/types@0.13.
|
|
324
|
-
- https://www.unpkg.com/@e-mc/types@0.13.
|
|
325
|
-
- https://www.unpkg.com/@e-mc/types@0.13.
|
|
326
|
-
- https://www.unpkg.com/@e-mc/types@0.13.
|
|
327
|
-
- https://www.unpkg.com/@e-mc/types@0.13.
|
|
328
|
-
- https://www.unpkg.com/@e-mc/types@0.13.
|
|
322
|
+
- https://www.unpkg.com/@e-mc/types@0.13.5/lib/squared.d.ts
|
|
323
|
+
- https://www.unpkg.com/@e-mc/types@0.13.5/lib/core.d.ts
|
|
324
|
+
- https://www.unpkg.com/@e-mc/types@0.13.5/lib/db.d.ts
|
|
325
|
+
- https://www.unpkg.com/@e-mc/types@0.13.5/lib/dom.d.ts
|
|
326
|
+
- https://www.unpkg.com/@e-mc/types@0.13.5/lib/logger.d.ts
|
|
327
|
+
- https://www.unpkg.com/@e-mc/types@0.13.5/lib/node.d.ts
|
|
328
|
+
- https://www.unpkg.com/@e-mc/types@0.13.5/lib/settings.d.ts
|
|
329
329
|
|
|
330
330
|
* https://www.npmjs.com/package/@types/node
|
|
331
331
|
|
package/index.js
CHANGED
|
@@ -281,6 +281,7 @@ class Host extends module_1 {
|
|
|
281
281
|
if (permission.unc_write) {
|
|
282
282
|
PERMISSION.setUNCWrite(unc_write);
|
|
283
283
|
}
|
|
284
|
+
Object.freeze(PERMISSION);
|
|
284
285
|
}
|
|
285
286
|
if (perm.settings) {
|
|
286
287
|
const { picomatch: pico, minimatch: mini } = perm.settings;
|
|
@@ -486,8 +487,8 @@ class Host extends module_1 {
|
|
|
486
487
|
static getLogDelayed() {
|
|
487
488
|
return HOST.LOG_DELAYED;
|
|
488
489
|
}
|
|
489
|
-
static getPermissionFromSettings() {
|
|
490
|
-
return PERMISSION;
|
|
490
|
+
static getPermissionFromSettings(freeze = true) {
|
|
491
|
+
return freeze ? PERMISSION : Permission.clone(PERMISSION);
|
|
491
492
|
}
|
|
492
493
|
restartable = true;
|
|
493
494
|
modules = new Set();
|
|
@@ -2017,3 +2018,4 @@ class Permission {
|
|
|
2017
2018
|
exports.Permission = Permission;
|
|
2018
2019
|
_a = Permission;
|
|
2019
2020
|
PERMISSION = Host.createPermission(true, true);
|
|
2021
|
+
Object.freeze(PERMISSION);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@e-mc/core",
|
|
3
|
-
"version": "0.13.
|
|
3
|
+
"version": "0.13.5",
|
|
4
4
|
"description": "Core modules for E-mc.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"types": "index.d.ts",
|
|
@@ -19,9 +19,9 @@
|
|
|
19
19
|
"license": "BSD-3-Clause",
|
|
20
20
|
"homepage": "https://github.com/anpham6/e-mc#readme",
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@e-mc/module": "0.13.
|
|
23
|
-
"@e-mc/types": "0.13.
|
|
24
|
-
"ipaddr.js": "^2.
|
|
22
|
+
"@e-mc/module": "0.13.5",
|
|
23
|
+
"@e-mc/types": "0.13.5",
|
|
24
|
+
"ipaddr.js": "^2.3.0",
|
|
25
25
|
"picomatch": "^4.0.3"
|
|
26
26
|
}
|
|
27
27
|
}
|