Skip to content

Commit

Permalink
refactor(gdoc): simplify subclass constructors
Browse files Browse the repository at this point in the history
  • Loading branch information
mlbrgl committed May 13, 2024
1 parent 52332f1 commit 739e1c4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
5 changes: 1 addition & 4 deletions db/model/Gdoc/GdocDataInsight.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,7 @@ export class GdocDataInsight
content!: OwidGdocDataInsightContent

constructor(id?: string) {
super()
if (id) {
this.id = id
}
super(id)
}

static create(obj: OwidGdocBaseInterface): GdocDataInsight {
Expand Down
5 changes: 1 addition & 4 deletions db/model/Gdoc/GdocHomepage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,7 @@ export class GdocHomepage
content!: OwidGdocHomepageContent

constructor(id?: string) {
super()
if (id) {
this.id = id
}
super(id)
}

static create(obj: OwidGdocBaseInterface): GdocHomepage {
Expand Down

0 comments on commit 739e1c4

Please sign in to comment.