Skip to content

Commit

Permalink
bug 修复
Browse files Browse the repository at this point in the history
  • Loading branch information
pakizheng committed Jan 11, 2024
1 parent 76e74d9 commit dc23bd0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/gateways/redis-io-adapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@ export class RedisIoAdapter extends IoAdapter {
private adapterConstructor: ReturnType<typeof createAdapter>;

async connectToRedis(): Promise<void> {
const pubClient = createClient({ url: `redis://106.53.170.67:6379` });
const pubClient = createClient({ url: `redis://127.0.0.1:6379` });
const subClient = pubClient.duplicate();

await Promise.all([pubClient.connect(), subClient.connect()]);

this.adapterConstructor = createAdapter(pubClient, subClient);
}


createIOServer(port: number, options?: ServerOptions): any {
const server = super.createIOServer(port, options);
server.adapter(this.adapterConstructor);
Expand Down

0 comments on commit dc23bd0

Please sign in to comment.