Fixes callback for creating modules.