refactor
All checks were successful
Deploy / deploy (push) Successful in 35s

This commit is contained in:
2025-12-26 01:18:54 +06:00
parent 2aca9bca08
commit 778f0a5687

View File

@@ -72,11 +72,13 @@ export default function (fastify: FastifyInstance) {
const namespace = fastify.io.of('/webrtc') const namespace = fastify.io.of('/webrtc')
const sockets = await namespace.fetchSockets() const sockets = await namespace.fetchSockets()
console.log(sockets)
const found = sockets.find(socket => socket.id === req.user!.id) const found = sockets.find(socket => socket.id === req.user!.id)
if (found) { if (found) {
found.data.displayName = input.displayName found.data.displayName = input.displayName
console.log('found.', found)
namespace.emit('clientChanged', found.id, socketToClient(found)) namespace.emit('clientChanged', found.id, socketToClient(found))
} }