Move server package out into rove-server
This commit is contained in:
parent
62d6213c1a
commit
6fb7ee598d
9 changed files with 27 additions and 41 deletions
|
@ -294,8 +294,11 @@ func (w *World) Enqueue(rover uuid.UUID, commands ...Command) error {
|
|||
defer w.cmdMutex.Unlock()
|
||||
|
||||
// Append the commands to the incoming set
|
||||
cmds := w.Incoming[rover]
|
||||
w.Incoming[rover] = append(cmds, commands...)
|
||||
if cmds, ok := w.Incoming[rover]; ok {
|
||||
w.Incoming[rover] = append(cmds, commands...)
|
||||
} else {
|
||||
w.Incoming[rover] = commands
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue