Refactoring module load mechanism.