Browse Source

Fix unsubscribe

pull/263/head
Silas Davis 8 years ago
parent
commit
92736f22e8
No known key found for this signature in database GPG Key ID: 4CBFD0FF2D395219
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      rpc/core/events.go

+ 1
- 1
rpc/core/events.go View File

@ -20,6 +20,6 @@ func Subscribe(wsCtx rpctypes.WSRPCContext, event string) (*ctypes.ResultSubscri
func Unsubscribe(wsCtx rpctypes.WSRPCContext, event string) (*ctypes.ResultUnsubscribe, error) {
log.Notice("Unsubscribe to event", "remote", wsCtx.GetRemoteAddr(), "event", event)
wsCtx.GetEventSwitch().RemoveListener(event)
wsCtx.GetEventSwitch().RemoveListenerForEvent(event, wsCtx.GetRemoteAddr())
return &ctypes.ResultUnsubscribe{}, nil
}

Loading…
Cancel
Save