changed the structure per Guillermo's request