This commit is contained in:
Tim Olson
2023-12-28 01:05:54 -04:00
parent 5772696044
commit 252db5f542

View File

@@ -55,10 +55,7 @@ async function sendVaultInfo(socket, chainId, owner) {
export async function loginAddress(socket, chainId, address) {
if( socket.user_room !== undefined)
socket.leave(socket.user_room)
if( address === undefined ) {
socket.emit('vaults', chainId, address, [])
}
else {
if( address ) {
socket.user_room = `${chainId}|${address}`
socket.join(socket.user_room)
console.log('joined user room', socket.user_room)