|
@@ -655,8 +655,10 @@ func chathistoryHandler(server *Server, client *Client, msg ircmsg.Message, rb *
|
655
|
655
|
} else {
|
656
|
656
|
// successful responses are sent as a chathistory or history batch
|
657
|
657
|
if listTargets {
|
658
|
|
- batchID := rb.StartNestedBatch("draft/chathistory-targets")
|
659
|
|
- defer rb.EndNestedBatch(batchID)
|
|
658
|
+ if rb.session.capabilities.Has(caps.Batch) { // #2066
|
|
659
|
+ batchID := rb.StartNestedBatch("draft/chathistory-targets")
|
|
660
|
+ defer rb.EndNestedBatch(batchID)
|
|
661
|
+ }
|
660
|
662
|
for _, target := range targets {
|
661
|
663
|
name := server.UnfoldName(target.CfName)
|
662
|
664
|
rb.Add(nil, server.name, "CHATHISTORY", "TARGETS", name,
|