removing duplicated code (Christian)