modified variable names to appease nick