onError

var onError: (error: Throwable?) -> Unit?

Error handler.

Handler is called whenever a connection error is encountered.