Skip to content
This repository has been archived by the owner on Jul 15, 2024. It is now read-only.

Commit

Permalink
chore: type cast as ShardOp
Browse files Browse the repository at this point in the history
  • Loading branch information
Hazmi35 authored Nov 15, 2023
1 parent e024498 commit 5fd9a52
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Utilities/WebSockets/ProcessBootstrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ export class ProcessBootstrapper {
public async onConsumeMessage(channel: Channel, message: ConsumeMessage | null) {
if (!message) return;
channel.ack(message);
const content = JSON.parse(message.content.toString()) as { op: number; data: unknown };
const content = JSON.parse(message.content.toString()) as { op: ShardOp; data: unknown };
const shardId = RoutingKeyToId(clientId, message.fields.routingKey);
switch (content.op) {
case ShardOp.SEND: {
Expand Down

0 comments on commit 5fd9a52

Please sign in to comment.