make sure disconnect is successful before stopping polling