phoenix-channel / ch.kuon.phoenix / Channel / onError

onError

fun onError(callback: (String) -> Unit): Ref

Register an error callback

Note: the callback might be called on another thread

Parameters

callback - A callback called when the channel has an error

Return
A ref that can be used with Channel.off