Why do we do this twice? Does the transport exit entirely or is this just aborting a command in progress? Is this sort of fix needed in other parts of this file?