made sure the criteria passed to getData() is used properly