Fixed email notification problem