Add TestHandleWS

This commit is contained in:
178inaba 2017-04-23 19:47:03 +09:00
parent f0857503d1
commit df768f24da
2 changed files with 87 additions and 37 deletions

View file

@ -112,9 +112,7 @@ func (c *Client) handleWS(ctx context.Context, rawurl string, q chan Event) erro
q <- &NotificationEvent{Notification: &notification}
}
case "delete":
if err == nil {
q <- &DeleteEvent{ID: int64(s.Payload.(float64))}
}
q <- &DeleteEvent{ID: int64(s.Payload.(float64))}
}
if err != nil {
q <- &ErrorEvent{err}