void onClose(Function callback) { on(ChannelEvents.close.eventName(), (reason, {ref}) => callback()); }