Skip to content

Instantly share code, notes, and snippets.

@Krishna21Soni13
Created January 3, 2020 10:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Krishna21Soni13/e2f299ce3c3732dea200c88635767f95 to your computer and use it in GitHub Desktop.
Save Krishna21Soni13/e2f299ce3c3732dea200c88635767f95 to your computer and use it in GitHub Desktop.
Leave the chat room.
func leaveChatRoom(nickname: String, completion: () -> Void) {
guard let socket = manager?.defaultSocket else{
return
}
socket.emit(kExitUser, nickname)
completion()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment