From 3da8fc4d4fd0c30741ee87cc3ed4f95ef191ca6c Mon Sep 17 00:00:00 2001 From: Gerasimos Maropoulos Date: Mon, 5 Sep 2016 17:34:47 +0300 Subject: [PATCH] Nothing special on Subscription (#5) --- messaging/publish_subscribe.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/messaging/publish_subscribe.md b/messaging/publish_subscribe.md index efb46b5..79d4405 100644 --- a/messaging/publish_subscribe.md +++ b/messaging/publish_subscribe.md @@ -27,11 +27,11 @@ type Subscription struct { } func (s *Subscription) Publish(msg Message) error { - if _, ok := ch; !ok { + if _, ok := s.ch; !ok { return errors.New("Topic has been closed") } - ch <- msg + s.ch <- msg return nil }