diff --git a/lib/structures/CalendarEvent.ts b/lib/structures/CalendarEvent.ts index 00819e9..d248422 100644 --- a/lib/structures/CalendarEvent.ts +++ b/lib/structures/CalendarEvent.ts @@ -77,7 +77,7 @@ export class CalendarEvent extends Base { this.color = data.color ?? null; this.rsvpLimit = data.rsvpLimit ?? null; this.startsAt = data.startsAt ? new Date(data.startsAt) : null; - this.duration = (data.duration as number) * 60000 ?? null; // in ms. + this.duration = data.duration ? data.duration * 60000 : null; // in ms. this.isPrivate = data.isPrivate ?? false; this.mentions = data.mentions ?? null; this.createdAt = data.createdAt ? new Date(data.createdAt) : null; diff --git a/tsconfig.json b/tsconfig.json index 4def560..1f4060e 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -24,7 +24,7 @@ "moduleResolution": "node", "allowUnusedLabels": false, "allowUnreachableCode": false, - "importsNotUsedAsValues": "error", + "verbatimModuleSyntax": true, "ignoreDeprecations": "5.0", "checkJs": true, "strictPropertyInitialization": true,