added extra logic to ensure job-cancel event gets broadcast