Clean up timeoutHandler a bit.