mirror of
https://github.com/ergochat/ergo.git
synced 2024-11-22 03:49:27 +01:00
parent
a6cf667f06
commit
ab870c2ffe
@ -9,6 +9,7 @@ import (
|
||||
"time"
|
||||
"unsafe"
|
||||
|
||||
"github.com/oragono/oragono/irc/caps"
|
||||
"github.com/oragono/oragono/irc/languages"
|
||||
"github.com/oragono/oragono/irc/modes"
|
||||
"github.com/oragono/oragono/irc/utils"
|
||||
@ -74,6 +75,7 @@ type SessionData struct {
|
||||
deviceID string
|
||||
connInfo string
|
||||
sessionID int64
|
||||
caps []string
|
||||
}
|
||||
|
||||
func (client *Client) AllSessionData(currentSession *Session, hasPrivs bool) (data []SessionData, currentIndex int) {
|
||||
@ -102,6 +104,7 @@ func (client *Client) AllSessionData(currentSession *Session, hasPrivs bool) (da
|
||||
if hasPrivs {
|
||||
data[i].connInfo = utils.DescribeConn(session.socket.conn.UnderlyingConn().Conn)
|
||||
}
|
||||
data[i].caps = session.capabilities.Strings(caps.Cap302, nil, 300)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
@ -1140,6 +1140,11 @@ func nsClientsListHandler(service *ircService, server *Server, client *Client, p
|
||||
if session.certfp != "" {
|
||||
service.Notice(rb, fmt.Sprintf(client.t("Certfp: %s"), session.certfp))
|
||||
}
|
||||
for _, capStr := range session.caps {
|
||||
if capStr != "" {
|
||||
service.Notice(rb, fmt.Sprintf(client.t("IRCv3 CAPs: %s"), capStr))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user