From 36d3e944ff3898616202f334b29ce3058c6e4209 Mon Sep 17 00:00:00 2001 From: mierenmanz Date: Thu, 29 Apr 2021 10:45:12 +0200 Subject: [PATCH] chore: update deps --- deps.ts | 6 +++--- src/gateway/mod.ts | 4 ++-- test/deps.ts | 2 ++ test/slash-http.ts | 2 +- test/unit.ts | 2 +- 5 files changed, 9 insertions(+), 7 deletions(-) create mode 100644 test/deps.ts diff --git a/deps.ts b/deps.ts index 43fc90c..114c537 100644 --- a/deps.ts +++ b/deps.ts @@ -1,6 +1,6 @@ -export { EventEmitter } from 'https://deno.land/x/event@0.2.1/mod.ts' +export { EventEmitter } from 'https://deno.land/x/event@1.0.0/mod.ts' export { unzlib } from 'https://denopkg.com/DjDeveloperr/denoflate@1.2/mod.ts' export { fetchAuto } from 'https://deno.land/x/fetchbase64@1.0.0/mod.ts' -export { walk } from 'https://deno.land/std@0.86.0/fs/walk.ts' -export { join } from 'https://deno.land/std@0.86.0/path/mod.ts' +export { walk } from 'https://deno.land/std@0.95.0/fs/walk.ts' +export { join } from 'https://deno.land/std@0.95.0/path/mod.ts' export { Mixin } from 'https://esm.sh/ts-mixer@5.4.0' diff --git a/src/gateway/mod.ts b/src/gateway/mod.ts index 6764095..e31b527 100644 --- a/src/gateway/mod.ts +++ b/src/gateway/mod.ts @@ -399,7 +399,7 @@ export class Gateway extends HarmonyEventEmitter { await this.cache.delete(`seq_${this.shards?.join('-') ?? '0'}`) } - this.close(1000, RECONNECT_REASON) + this.closeGateway(1000, RECONNECT_REASON) this.initWebsocket() } @@ -418,7 +418,7 @@ export class Gateway extends HarmonyEventEmitter { this.websocket.onerror = this.onerror.bind(this) as any } - close(code: number = 1000, reason?: string): void { + closeGateway(code: number = 1000, reason?: string): void { this.debug( `Closing with code ${code}${ reason !== undefined && reason !== '' ? ` and reason ${reason}` : '' diff --git a/test/deps.ts b/test/deps.ts new file mode 100644 index 0000000..0f6a35a --- /dev/null +++ b/test/deps.ts @@ -0,0 +1,2 @@ +export * from "https://deno.land/std@0.95.0/testing/asserts.ts" +export * from "https://deno.land/std@0.95.0/http/server.ts" \ No newline at end of file diff --git a/test/slash-http.ts b/test/slash-http.ts index 6ed7188..3ab4345 100644 --- a/test/slash-http.ts +++ b/test/slash-http.ts @@ -1,6 +1,6 @@ import { SlashClient } from '../mod.ts' import { SLASH_ID, SLASH_PUB_KEY, SLASH_TOKEN } from './config.ts' -import { listenAndServe } from 'https://deno.land/std@0.90.0/http/server.ts' +import { listenAndServe } from './deps.ts' const slash = new SlashClient({ id: SLASH_ID, diff --git a/test/unit.ts b/test/unit.ts index 5395f69..af98d46 100644 --- a/test/unit.ts +++ b/test/unit.ts @@ -5,7 +5,7 @@ import { TOKEN } from '../src/test/config.ts' import { assertEquals, assertExists -} from 'https://deno.land/std@0.84.0/testing/asserts.ts' +} from './deps.ts' //#region Lib Tests Deno.test({