3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-24 21:09:30 +01:00

Merge pull request #1998 from slingamn/away

fix #1996
This commit is contained in:
Shivaram Lingamneni 2022-09-11 01:44:18 -07:00 committed by GitHub
commit a9c77af1cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -449,10 +449,10 @@ func awayHandler(server *Server, client *Client, msg ircmsg.Message, rb *Respons
var isAway bool var isAway bool
var awayMessage string var awayMessage string
if len(msg.Params) > 0 { if len(msg.Params) > 0 {
isAway = true
awayMessage = msg.Params[0] awayMessage = msg.Params[0]
awayMessage = ircutils.TruncateUTF8Safe(awayMessage, server.Config().Limits.AwayLen) awayMessage = ircutils.TruncateUTF8Safe(awayMessage, server.Config().Limits.AwayLen)
} }
isAway = (awayMessage != "") // #1996
rb.session.SetAway(awayMessage) rb.session.SetAway(awayMessage)