changed the code excerpt