Small fixes

Fixed a NPE on connection failure
Fixed a dependent on scheduler magic (failed for me)