Skip to content

Commit

Permalink
Merge pull request #62 from pubkey/master
Browse files Browse the repository at this point in the history
Fix typings, MinimongoCollection needs generic
  • Loading branch information
grassick authored Feb 4, 2020
2 parents 8f46f37 + 6be2710 commit c856892
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ export class MinimongoDb {
getCollectionNames(): string[]
localDb?: MinimongoDb
remoteDb?: MinimongoDb
collections: { [collectionName: string]: MinimongoCollection<any> }
collections: { [collectionName: string]: MinimongoCollection }
}

export interface MinimongoCollection<ItemType> {
export interface MinimongoCollection<ItemType = any> {
find(selector: any, options?: MinimongoCollectionFindOptions): {
fetch(success: (items: ItemType[]) => void, error: (err: any) => void): void
}
Expand Down

0 comments on commit c856892

Please sign in to comment.