cleaned up data access and finalized module