Role of topology on the work distribution function of a quenched Haldane model of graphene