client/operations.go
func (op *operation) RemoveHandler(target *EventTarget) error {
	// Make sure we're not racing with ourselves
	op.handlerLock.Lock()
	defer op.handlerLock.Unlock()

	// If the listener is gone, just return
	if op.listener == nil {
		return nil
	}

	return op.listener.RemoveHandler(target)
}
func (op *operation) RemoveHandler(target *EventTarget) error {
	// Make sure we're not racing with ourselves
	op.handlerLock.Lock()
	defer op.handlerLock.Unlock()

	// If the listener is gone, just return
	if op.listener == nil {
		return nil
	}

	return op.listener.RemoveHandler(target)
}
func ( op * operation ) RemoveHandler ( target * EventTarget ) error { // Make sure we're not racing with ourselves op . handlerLock . Lock ( ) defer op . handlerLock . Unlock ( ) // If the listener is gone, just return if op . listener == nil { return nil } return op . listener . RemoveHandler ( target ) }
// RemoveHandler removes a function to be called whenever an event is received
RemoveHandler removes a function to be called whenever an event is received