Mass replace parameter order (socket,io)>(io,socket), worked on queueing system
This commit is contained in:
9
src/socketEvents/login.ts
Normal file
9
src/socketEvents/login.ts
Normal file
@ -0,0 +1,9 @@
|
||||
import { Server } from 'socket.io'
|
||||
import { TSocket } from '../utilities/types'
|
||||
|
||||
export default function (io: Server, socket: TSocket) {
|
||||
socket.on('login', () => {
|
||||
if (!socket.user) return
|
||||
socket.emit('logged_in', { user: socket.user })
|
||||
})
|
||||
}
|
Reference in New Issue
Block a user