MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / optionalColumn

Function optionalColumn

apps/local/src/db/v1-v2-migration.ts:152–153  ·  view source on GitHub ↗
(columns: ReadonlySet<string>, table: string, column: string)

Source from the content-addressed store, hash-verified

150 );
151
152const optionalColumn = (columns: ReadonlySet<string>, table: string, column: string): string =>
153 columns.has(column) ? `${quoteIdent(table)}.${quoteIdent(column)}` : "NULL";
154
155const isLocalV1Database = async (client: Client): Promise<boolean> => {
156 if (!(await tableExists(client, "source"))) return false;

Callers 1

readV1SnapshotFunction · 0.85

Calls 1

quoteIdentFunction · 0.70

Tested by

no test coverage detected