Added missing notificationMsg types to notificationHandler

This commit is contained in:
Francis Lam 2014-03-04 21:36:48 -05:00
parent b452acdde2
commit 33af740985

View file

@ -291,6 +291,10 @@ out:
wsc := (*wsClient)(n) wsc := (*wsClient)(n)
blockNotifications[wsc.quit] = wsc blockNotifications[wsc.quit] = wsc
case *notificationUnregisterBlocks:
wsc := (*wsClient)(n)
delete(blockNotifications, wsc.quit)
case *notificationRegisterClient: case *notificationRegisterClient:
wsc := (*wsClient)(n) wsc := (*wsClient)(n)
clients[wsc.quit] = wsc clients[wsc.quit] = wsc
@ -322,6 +326,14 @@ out:
case *notificationUnregisterAddr: case *notificationUnregisterAddr:
m.removeAddrRequest(watchedAddrs, n.wsc, n.addr) m.removeAddrRequest(watchedAddrs, n.wsc, n.addr)
case *notificationRegisterNewMempoolTxs:
wsc := (*wsClient)(n)
txNotifications[wsc.quit] = wsc
case *notificationUnregisterNewMempoolTxs:
wsc := (*wsClient)(n)
delete(txNotifications, wsc.quit)
default: default:
rpcsLog.Warn("Unhandled notification type") rpcsLog.Warn("Unhandled notification type")
} }