ack-bug-fix
This commit is contained in:
@@ -164,11 +164,6 @@ async function main() {
|
|||||||
.subscribe(redisChannel)
|
.subscribe(redisChannel)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
subscribedChannels.add(redisChannel);
|
subscribedChannels.add(redisChannel);
|
||||||
ws.send(
|
|
||||||
JSON.stringify({
|
|
||||||
message: `Subscribe received for channel: ${parsedMessage.channel}, market: ${parsedMessage.market}, marketType: ${parsedMessage.marketType}`,
|
|
||||||
})
|
|
||||||
);
|
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
ws.send(
|
ws.send(
|
||||||
@@ -186,6 +181,11 @@ async function main() {
|
|||||||
}
|
}
|
||||||
channelSubscribers.get(redisChannel).add(ws);
|
channelSubscribers.get(redisChannel).add(ws);
|
||||||
|
|
||||||
|
ws.send(
|
||||||
|
JSON.stringify({
|
||||||
|
message: `Subscribe received for channel: ${parsedMessage.channel}, market: ${parsedMessage.market}, marketType: ${parsedMessage.marketType}`,
|
||||||
|
})
|
||||||
|
);
|
||||||
// Fetch and send last message
|
// Fetch and send last message
|
||||||
if (redisChannel.includes('orderbook')) {
|
if (redisChannel.includes('orderbook')) {
|
||||||
const lastUpdateChannel = `last_update_${redisChannel}`;
|
const lastUpdateChannel = `last_update_${redisChannel}`;
|
||||||
|
|||||||
Reference in New Issue
Block a user