Close client after scheduler disconnect

Signed-off-by: Lewis Marshall <lewis@lmars.net>