[codex] fix cross-database JSON boundary handling (#283)

* fix: normalize cross-database json boundaries

* fix: address json boundary review comments

---------

Co-authored-by: apple <apple@appledeMacBook-Pro.local>
This commit is contained in:
Cita
2026-03-26 20:21:19 +08:00
committed by GitHub
parent 7e1fb8eb1b
commit b3387dfba7
30 changed files with 1134 additions and 97 deletions
+6 -1
View File
@@ -117,7 +117,8 @@ export async function refreshProxyVideoTaskSnapshot(
.run();
}
function parseJsonColumn(value: string | null | undefined): unknown | null {
function parseJsonColumn(value: unknown): unknown | null {
if (value && typeof value === 'object') return value;
if (typeof value !== 'string' || value.trim().length === 0) return null;
try {
return JSON.parse(value);
@@ -125,3 +126,7 @@ function parseJsonColumn(value: string | null | undefined): unknown | null {
return value;
}
}
export const __proxyVideoTaskStoreTestUtils = {
parseJsonColumn,
};