restructured as a module