Skip to content
This repository was archived by the owner on Jan 1, 2025. It is now read-only.

Commit c38ba16

Browse files
authored
Merge pull request #288 from plexidev/fix/prepare-db
Fix db not prepared by adding init method
2 parents 0a18b98 + ffd8c66 commit c38ba16

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,11 @@ export class QuickDB<D = any> {
9494
return this.instance;
9595
}
9696

97+
async init(): Promise<void> {
98+
// TODO: change this to remove prepared and call prepare here instead
99+
await this.prepared;
100+
}
101+
97102
async all<T = D>(): Promise<{ id: string; value: T }[]> {
98103
return this.driver.getAllRows(this.tableName);
99104
}

0 commit comments

Comments
 (0)