From fff3d965c82be43ce482d9ddd246b07121abf887 Mon Sep 17 00:00:00 2001 From: Tsu-ba-me Date: Fri, 5 Jan 2024 17:43:22 -0500 Subject: [PATCH] fix(striker-ui-api): remove unused root access to perl modules --- striker-ui-api/src/lib/accessModule.ts | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/striker-ui-api/src/lib/accessModule.ts b/striker-ui-api/src/lib/accessModule.ts index 94a0f6aa..ab2a4d28 100644 --- a/striker-ui-api/src/lib/accessModule.ts +++ b/striker-ui-api/src/lib/accessModule.ts @@ -190,21 +190,17 @@ class Access extends EventEmitter { } const access = new Access(); -const rootAccess = new Access({ spawnOptions: { gid: 0, uid: 0 } }); const subroutine = async ( subroutine: string, { params = [], pre = ['Database'], - root, }: { params?: unknown[]; pre?: string[]; - root?: boolean; } = {}, ) => { - const selectedAccess = root ? rootAccess : access; const chain = `${pre.join('->')}->${subroutine}`; const subParams: string[] = params.map((p) => { @@ -219,7 +215,7 @@ const subroutine = async ( return `"${result.replaceAll('"', '\\"')}"`; }); - const { sub_results: results } = await selectedAccess.interact<{ + const { sub_results: results } = await access.interact<{ sub_results: T; }>('x', chain, ...subParams);