Skip to content

Commit

Permalink
fix(core-webooks): ignore random type errors thrown by lowdb on build (
Browse files Browse the repository at this point in the history
  • Loading branch information
deanpress authored Sep 10, 2020
1 parent b8afdb4 commit 785680c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/core-webhooks/src/database.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ class Database {
try {
return this.database
.get("webhooks")
// @ts-ignore
.find({ id })
.value();
} catch (error) {
Expand All @@ -40,6 +41,7 @@ class Database {
public findByEvent(event: string): IWebhook[] {
return this.database
.get("webhooks")
// @ts-ignore
.filter({ event })
.value();
}
Expand All @@ -49,6 +51,7 @@ class Database {

this.database
.get("webhooks")
// @ts-ignore
.push(data)
.write();

Expand All @@ -58,6 +61,7 @@ class Database {
public update(id: string, data: IWebhook): IWebhook {
return this.database
.get("webhooks")
// @ts-ignore
.find({ id })
.assign(data)
.write();
Expand All @@ -66,6 +70,7 @@ class Database {
public destroy(id: string): void {
this.database
.get("webhooks")
// @ts-ignore
.remove({ id })
.write();
}
Expand Down

0 comments on commit 785680c

Please sign in to comment.