restructured to be closer to clean. still failing to access private fields from other portions of the module