Don't try to populate map that doesn't exist
This commit is contained in:
parent
dd7f69ffc3
commit
15d44cd707
|
@ -110,7 +110,9 @@ func (r *Inputer) InputRoomEvents(
|
||||||
func (r *Inputer) WriteOutputEvents(roomID string, updates []api.OutputEvent) error {
|
func (r *Inputer) WriteOutputEvents(roomID string, updates []api.OutputEvent) error {
|
||||||
var err error
|
var err error
|
||||||
for _, update := range updates {
|
for _, update := range updates {
|
||||||
msg := &nats.Msg{}
|
msg := &nats.Msg{
|
||||||
|
Header: nats.Header{},
|
||||||
|
}
|
||||||
msg.Header.Set(jetstream.RoomID, roomID)
|
msg.Header.Set(jetstream.RoomID, roomID)
|
||||||
msg.Data, err = json.Marshal(update)
|
msg.Data, err = json.Marshal(update)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in a new issue