Fix bug with Cancel Button