Skip to content

Commit

Permalink
Fix projection updates getting stuck
Browse files Browse the repository at this point in the history
  • Loading branch information
bastianjoel committed Jan 27, 2025
1 parent 2865f0f commit 6785c5c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/datastore/subscribe.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func (q *query[T, PT]) Subscribe() *subscription[<-chan map[string]map[string]in
}()

return &subscription[<-chan map[string]map[string]interface{}]{q.datastore, updateChannel, func() error { return nil }, notifyChannel, func() {
close(notifyChannel)
q.datastore.change.RemoveListener <- updateChannel
}}
}

Expand Down Expand Up @@ -141,7 +141,7 @@ func (q *query[T, PT]) SubscribeOne(model PT) (*subscription[<-chan []string], e
}()

return &subscription[<-chan []string]{q.datastore, updateChannel, load, notifyChannel, func() {
close(notifyChannel)
q.datastore.change.RemoveListener <- updateChannel
}}, nil
}

Expand Down

0 comments on commit 6785c5c

Please sign in to comment.