Fix database setup, test encryption and repositories - all working

Co-authored-by: southseact-3d <217551146+southseact-3d@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-02-09 19:37:28 +00:00
parent 650d849ad2
commit fd6d2d641b
7 changed files with 539 additions and 20 deletions

View File

@@ -67,18 +67,11 @@ async function setupDatabase() {
const db = getDatabase();
// Split by semicolon and execute each statement
const statements = schema
.split(';')
.map(s => s.trim())
.filter(s => s.length > 0 && !s.startsWith('--'));
for (const statement of statements) {
db.exec(statement);
}
// Execute the entire schema as one block
// SQLite can handle multiple statements with exec()
db.exec(schema);
console.log('✅ Database schema created');
console.log(` Executed ${statements.length} SQL statements`);
} catch (error) {
console.error('❌ Failed to create schema:', error.message);
closeDatabase();