mirror of
https://mau.dev/mautrix/go.git
synced 2026-03-14 14:25:53 +01:00
event: use RawMessage instead of map for bot command arguments
This commit is contained in:
parent
cd927c2796
commit
61a90da145
1 changed files with 6 additions and 2 deletions
|
|
@ -6,6 +6,10 @@
|
|||
|
||||
package event
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
)
|
||||
|
||||
type BotCommandsEventContent struct {
|
||||
Sigil string `json:"sigil,omitempty"`
|
||||
Commands []*BotCommand `json:"commands,omitempty"`
|
||||
|
|
@ -40,6 +44,6 @@ type BotCommandArgument struct {
|
|||
}
|
||||
|
||||
type BotCommandInput struct {
|
||||
Syntax string `json:"syntax"`
|
||||
Arguments map[string]any `json:"arguments,omitempty"`
|
||||
Syntax string `json:"syntax"`
|
||||
Arguments json.RawMessage `json:"arguments,omitempty"`
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue