Now emits events when replacing a link