Browse Source

fix roleplay messages not being relayed

See #865.
tags/v2.1.0-rc1
Shivaram Lingamneni 4 years ago
parent
commit
2bb36e6cb8
1 changed files with 5 additions and 4 deletions
  1. 5
    4
      irc/roleplay.go

+ 5
- 4
irc/roleplay.go View File

@@ -47,11 +47,12 @@ func sendRoleplayMessage(server *Server, client *Client, source string, targetSt
47 47
 
48 48
 		for _, member := range channel.Members() {
49 49
 			for _, session := range member.Sessions() {
50
-				if member == client && !session.capabilities.Has(caps.EchoMessage) {
51
-					continue
52
-				} else if rb.session == session {
50
+				// see discussion on #865: clients do not understand how to do local echo
51
+				// of roleplay commands, so send them a copy whether they have echo-message
52
+				// or not
53
+				if rb.session == session {
53 54
 					rb.Add(nil, source, "PRIVMSG", channel.name, message)
54
-				} else if member == client || session.capabilities.Has(caps.EchoMessage) {
55
+				} else {
55 56
 					session.Send(nil, source, "PRIVMSG", channel.name, message)
56 57
 				}
57 58
 			}

Loading…
Cancel
Save