create empty client, add function of collecting user unread messages on channels
This commit is contained in:
@@ -288,7 +288,7 @@ func HandleHubJoin(response http.ResponseWriter, request *http.Request) {
|
||||
})
|
||||
}
|
||||
|
||||
func HandleHubMessage(response http.ResponseWriter, request *http.Request) {
|
||||
func HandleHubChannelMessage(response http.ResponseWriter, request *http.Request) {
|
||||
if !validCheckWithResponseOnFail(response, request, normal) {
|
||||
return
|
||||
}
|
||||
|
||||
@@ -64,6 +64,8 @@ func HandleUserNewToken(response http.ResponseWriter, request *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
user.ChannelUnreadMessage = make(map[uuid.UUID]uint8)
|
||||
|
||||
cache.SaveUser(user)
|
||||
|
||||
token, err := tokens.TokenCreate(user.Id)
|
||||
|
||||
Reference in New Issue
Block a user