Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function wrappedSQLiteDatabase (name) {
const db = new SQLiteDatabase(name);
if (CFG.sqlBusyTimeout) {
db._db.configure('busyTimeout', CFG.sqlBusyTimeout); // Default is 1000
}
if (CFG.sqlTrace) {
db._db.configure('trace', CFG.sqlTrace);
}
if (CFG.sqlProfile) {
db._db.configure('profile', CFG.sqlProfile);
}
return db;
}