aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBohdan Horbeshko <bodqhrohro@gmail.com>2024-02-03 18:38:00 +0300
committerBohdan Horbeshko <bodqhrohro@gmail.com>2024-02-03 18:38:00 +0300
commita0180eff7551ec89f2a925dba69ba547ad0e5d60 (patch)
tree90dbd5638b7b7f4ef30abf06ed96c9c1afe8881d
parente7d5a2a2666adc13c3046e89b30fae87aa5d06e3 (diff)
Handle command cancelling
-rw-r--r--xmpp/handlers.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/xmpp/handlers.go b/xmpp/handlers.go
index c6406e9..6fb1af2 100644
--- a/xmpp/handlers.go
+++ b/xmpp/handlers.go
@@ -760,6 +760,12 @@ func handleSetQueryCommand(s xmpp.Sender, iq *stanza.IQ, command *stanza.Command
} else {
cmdString = "/" + command.Node
}
+ } else if command.Action == stanza.CommandActionCancel {
+ answer.Payload = &stanza.Command{
+ SessionId: command.Node,
+ Node: command.Node,
+ Status: stanza.CommandStatusCancelled,
+ }
}
}
}