commit 4c62442
delthas
·
2025-08-03 18:29:34 +0000 UTC
parent fb47f06
Fix panic on PRIVMSG/NOTICE without a prefix Thanks to cjj for finding the issue. Thanks to gamesurge for hosting an obsolete IRCd ;-) Fixes: https://todo.sr.ht/~delthas/senpai/208
1 files changed,
+2,
-2
M
app.go
M
app.go
+2,
-2
1@@ -1498,8 +1498,8 @@ func (app *App) handleIRCEvent(netID string, ev interface{}) {
2 current := app.win.Focused() && curNetID == netID && curBuffer == buffer
3 app.notifyHighlight(buffer, ev.User, line.Body.String(), current)
4 }
5- if !s.IsChannel(msg.Params[0]) && !s.IsMe(ev.User) {
6- app.lastQuery = msg.Prefix.Name
7+ if !ev.TargetIsChannel && !s.IsMe(ev.User) {
8+ app.lastQuery = ev.User
9 app.lastQueryNet = netID
10 }
11 bk := boundKey{netID, s.Casemap(buffer)}