check error

pull/5/head
Yasuhiro Matsumoto 2017-04-14 12:23:20 +09:00
parent d8dfefc0ed
commit 23e9f80935
1 changed files with 4 additions and 2 deletions

View File

@ -314,8 +314,10 @@ func (c *Client) StreamingPublic(ctx context.Context) (chan Event, error) {
switch name {
case "update":
var status Status
json.Unmarshal([]byte(token[1]), &status)
q <- &UpdateEvent{&status}
err = json.Unmarshal([]byte(token[1]), &status)
if err == nil {
q <- &UpdateEvent{&status}
}
case "notification":
case "delete":
}