fix according to Ambrose's comments