We must not use variable if it is not yet set — we must set channel in "init" handler, but not in "connected" handler. Issue is actual under windows (I don't know why).
fix possible NPE