Skip to content

HooEP01/go-websocket

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Websocket

  1. params: user_id & channel_id

Improvement

// user modal
// user.is_online

// On user reconnect logic
func onUserReconnect(user *User) {
	messages := RetrieveMessagesForUser(user.ID)
	for _, message := range messages {
	    user.Conn.WriteMessage(websocket.TextMessage, []byte(message.Content))
	}
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages