refactor(agents): trim auth persistence exports · openclaw/openclaw@7186f0d
vincentkoc
·
2026-06-17
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -36,7 +36,7 @@ import type {
|
36 | 36 | } from "./types.js"; |
37 | 37 | |
38 | 38 | /** Legacy auth.json store shape before auth-profiles.json/SQLite. */ |
39 | | -export type LegacyAuthStore = Record<string, AuthProfileCredential>; |
| 39 | +type LegacyAuthStore = Record<string, AuthProfileCredential>; |
40 | 40 | |
41 | 41 | type LoadPersistedAuthProfileStoreOptions = { |
42 | 42 | allowKeychainPrompt?: boolean; |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -17,7 +17,6 @@ import { requireNodeSqlite } from "../../infra/node-sqlite.js";
|
17 | 17 | import { resolveSqliteDatabaseFilePaths } from "../../infra/sqlite-files.js"; |
18 | 18 | import type { DB as OpenClawAgentKyselyDatabase } from "../../state/openclaw-agent-db.generated.js"; |
19 | 19 | import { |
20 | | -openOpenClawAgentDatabase, |
21 | 20 | runOpenClawAgentWriteTransaction, |
22 | 21 | type OpenClawAgentDatabase, |
23 | 22 | } from "../../state/openclaw-agent-db.js"; |
@@ -88,11 +87,6 @@ function getAuthProfileKysely(db: DatabaseSync) {
|
88 | 87 | return getNodeSqliteKysely<AuthProfileDatabase>(db); |
89 | 88 | } |
90 | 89 | |
91 | | -/** Opens the auth profile SQLite database for an agent dir. */ |
92 | | -export function openAuthProfileDatabase(agentDir?: string): OpenClawAgentDatabase { |
93 | | -return openOpenClawAgentDatabase(resolveAuthProfileDatabaseOptions(agentDir)); |
94 | | -} |
95 | | - |
96 | 90 | function readAuthProfileJsonCellReadOnly(pathname: string, target: "store" | "state"): unknown { |
97 | 91 | const sqlite = requireNodeSqlite(); |
98 | 92 | const db = new sqlite.DatabaseSync(pathname, { readOnly: true }); |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。