Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
DerGoogler committed Sep 9, 2024
1 parent 50fa7a8 commit 7a7e284
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
"markdown-to-jsx": "^7.4.0",
"material-icons": "^1.10.8",
"material-ui-confirm": "^3.0.16",
"modfs": "^1.3.2",
"modfs": "^1.4.2",
"monaco-editor": "^0.48.0",
"monaco-editor-core": "^0.50.0",
"monaco-languageclient": "^6.5.0",
Expand Down
3 changes: 3 additions & 0 deletions src/native/IsolatedEval/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import { IsoXMLSerializer } from "./IsoXMLSerializer";
import { IsolatedEvalError } from "./IsolatedEvalError";
import { IsolatedFunctionBlockError } from "./IsolatedFunctionBlockError";
import { InternalReact } from "@Activitys/ModConfActivity/components/ModConfView/libs";
import ModFS from "modfs";

type IsoModule = {
exports: {
Expand Down Expand Up @@ -71,6 +72,7 @@ class IsolatedEval<T = any> {
os: os,
BuildConfig: BuildConfig,
Build: Build,
ModFS: ModFS,
Native: Native,
React: InternalReact,
setInterval: setInterval,
Expand Down Expand Up @@ -138,6 +140,7 @@ class IsolatedEval<T = any> {
this._prototypeWhitelist.set(Chooser, new Set());
this._prototypeWhitelist.set(Path, new Set());
this._prototypeWhitelist.set(React, new Set());
this._prototypeWhitelist.set(ModFS, new Set());

this.require = this.require.bind(this);
this._resolveModule = this._resolveModule.bind(this);
Expand Down
4 changes: 3 additions & 1 deletion src/native/Shell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ interface NativeShellV2 extends NativeShell {
};
}

type RootManager = "Magisk" | "KernelSU" | "APatchSU" | "Unknown";

/**
* Run Shell commands native on Android
*/
Expand Down Expand Up @@ -152,7 +154,7 @@ class Shell extends Native<NativeShellV2> {
}
}

public static getRootManager(): string {
public static getRootManager(): RootManager {
if (this.isMagiskSU()) {
return "Magisk";
} else if (this.isKernelSU()) {
Expand Down

0 comments on commit 7a7e284

Please sign in to comment.