muerto el perro, se acabó la rabia

Proverb

 * 1) to deal with a problem, it is necessary to nip it in the bud