Refactor new_worker