MCPcopy Index your code
hub / github.com/ChatLab/ChatLab / getDatabaseConstructor

Function getDatabaseConstructor

tests/e2e/smoke/chart-runtime.smoke.test.js:119–124  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

117let Database = null
118
119function getDatabaseConstructor() {
120 if (Database) return Database
121 const nodeRuntimePackageJson = path.resolve(__dirname, '../../../packages/node-runtime/package.json')
122 Database = createRequire(nodeRuntimePackageJson)('better-sqlite3')
123 return Database
124}
125
126function resolveNativeBinding() {
127 if (process.env.CHATLAB_TEST_SQLITE_NATIVE_BINDING) {

Callers 2

seedChatSessionDbFunction · 0.85
seedAiConversationDbFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected