Mail alter when a device is deleted. Fix #37.