onError method
void
onError(
- dynamic error
Implementation
void onError(error) {
done = true;
// close socket on error
// follow bug https://github.com/ra1u/redis-dart/issues/49
// and bug https://github.com/dart-lang/sdk/issues/47538
socket.close().then<void>((_){
if (_nfut >= 1) {
_nfut = 0;
for (Completer<List<int>> e in _queue) {
e.completeError(error);
}
}
});
}