mirror of
https://github.com/raz-varren/sacrificial-socket.git
synced 2025-10-25 09:00:39 +08:00
documentation == helpful
This commit is contained in:
@@ -75,6 +75,7 @@ func (s *Socket) send(data interface{}) error {
|
|||||||
return websocket.Message.Send(s.ws, data)
|
return websocket.Message.Send(s.ws, data)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//InRoom returns true if s is currently a member of roomName
|
||||||
func (s *Socket) InRoom(roomName string) bool {
|
func (s *Socket) InRoom(roomName string) bool {
|
||||||
s.roomsl.RLock()
|
s.roomsl.RLock()
|
||||||
defer s.roomsl.RUnlock()
|
defer s.roomsl.RUnlock()
|
||||||
|
|||||||
Reference in New Issue
Block a user