fix error caused by "commit b1d3184f: add support for disconnection"