From d923a92b4efb98fa49c560516b5986cafa887e07 Mon Sep 17 00:00:00 2001 From: Nico Date: Mon, 8 Apr 2024 16:23:28 -0400 Subject: [PATCH] fix: status default (#249) * fix: status default * Create fresh-apricots-train.md * fix: types --- .changeset/fresh-apricots-train.md | 5 +++++ packages/guilded.js/lib/structures/Client.ts | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) create mode 100644 .changeset/fresh-apricots-train.md diff --git a/.changeset/fresh-apricots-train.md b/.changeset/fresh-apricots-train.md new file mode 100644 index 00000000..9acb2889 --- /dev/null +++ b/.changeset/fresh-apricots-train.md @@ -0,0 +1,5 @@ +--- +"guilded.js": patch +--- + +fix: status default diff --git a/packages/guilded.js/lib/structures/Client.ts b/packages/guilded.js/lib/structures/Client.ts index 4507a18f..e59963a1 100644 --- a/packages/guilded.js/lib/structures/Client.ts +++ b/packages/guilded.js/lib/structures/Client.ts @@ -231,7 +231,7 @@ export class Client extends (EventEmitter as unknown as new () => TypedEmitter { - let resolvedDate: Date; + let resolvedDate: Date | undefined; if (options.expiresAt instanceof Date) { resolvedDate = options.expiresAt; } else if (typeof options.expiresAt === "string") { @@ -239,7 +239,7 @@ export class Client extends (EventEmitter as unknown as new () => TypedEmitter TypedEmitter