Simplify by making command streams pointer lists like in proto

This commit is contained in:
Marc Di Luzio 2020-07-21 23:52:14 +01:00
parent f78efd1223
commit 8667f55143
6 changed files with 143 additions and 193 deletions

View file

@ -243,8 +243,8 @@ func InnerMain(command string, args ...string) error {
}
commands = append(commands,
&roveapi.Command{
Command: roveapi.CommandType_broadcast,
Data: &roveapi.Command_Broadcast{Broadcast: []byte(args[i])},
Command: roveapi.CommandType_broadcast,
Broadcast: []byte(args[i]),
},
)
case "broadcast":
@ -256,8 +256,8 @@ func InnerMain(command string, args ...string) error {
}
commands = append(commands,
&roveapi.Command{
Command: roveapi.CommandType_broadcast,
Data: &roveapi.Command_Broadcast{Broadcast: []byte(args[i])},
Command: roveapi.CommandType_broadcast,
Broadcast: []byte(args[i]),
},
)
default: