Remove better-sqlite3
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import Database from "better-sqlite3";
|
||||
import { DatabaseSync } from 'node:sqlite'
|
||||
import { deserializeInvitation, serializeInvitation } from "@xo-cash/engine";
|
||||
import type { XOInvitation } from "@xo-cash/types";
|
||||
|
||||
@@ -22,7 +22,7 @@ export abstract class BaseStorage {
|
||||
export class Storage extends BaseStorage {
|
||||
static async create(dbPath: string): Promise<Storage> {
|
||||
// Create the database
|
||||
const database = new Database(dbPath);
|
||||
const database = new DatabaseSync(dbPath);
|
||||
|
||||
// Create the storage table if it doesn't exist
|
||||
database
|
||||
@@ -35,7 +35,7 @@ export class Storage extends BaseStorage {
|
||||
}
|
||||
|
||||
constructor(
|
||||
private readonly database: Database.Database,
|
||||
private readonly database: DatabaseSync,
|
||||
private readonly basePath: string,
|
||||
) {
|
||||
super();
|
||||
|
||||
Reference in New Issue
Block a user