Commit ae9a6913 authored by Chunchi Che's avatar Chunchi Che

fix handleSocketMessage

parent 94b7862d
Pipeline #23661 passed with stages
in 15 minutes and 16 seconds
......@@ -40,8 +40,7 @@ export default async function handleSocketMessage(e: MessageEvent) {
async function _handle(e: MessageEvent) {
const packets = YgoProPacket.deserialize(e.data);
await Promise.all(
packets.map(async (packet) => {
for (const packet of packets) {
const pb = adaptStoc(packet);
switch (pb.msg) {
......@@ -124,6 +123,5 @@ async function _handle(e: MessageEvent) {
break;
}
}
}),
);
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment