Updated moduleLoader procedure.