Another attempted fix for the disconnect/connect bugs.