mirror of
https://github.com/aljazceru/ditto.git
synced 2026-01-06 23:24:22 +01:00
Enable WAL mode on the database
This commit is contained in:
9
src/db/migrations/008_wal.ts
Normal file
9
src/db/migrations/008_wal.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
import { Kysely, sql } from '@/deps.ts';
|
||||
|
||||
export async function up(db: Kysely<any>): Promise<void> {
|
||||
await sql`PRAGMA journal_mode = WAL`.execute(db);
|
||||
}
|
||||
|
||||
export async function down(db: Kysely<any>): Promise<void> {
|
||||
await sql`PRAGMA journal_mode = DELETE`.execute(db);
|
||||
}
|
||||
Reference in New Issue
Block a user