Skip to content

Commit

Permalink
fix database types
Browse files Browse the repository at this point in the history
  • Loading branch information
jleeson committed May 29, 2024
1 parent ed64765 commit e349674
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
/* implement a database using the firefly database interface */
class CustomDatabase extends Database {

async connect(): Promise<void> {
async connect(): Promise<CustomDatabase> {
super.displayConnectionMessage();
return this;
}

isConnected(): boolean {
Expand Down
2 changes: 1 addition & 1 deletion packages/firefly/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ declare module "@outwalk/firefly/mongoose" {
constructor(options?: { url?: string; } & ConnectOptions);

plugin(plugin: any): void;
connect(): Promise<Database>;
connect(): Promise<MongooseDatabase>;
isConnected(): boolean;

static get connection(): Connection;
Expand Down

0 comments on commit e349674

Please sign in to comment.