RegisterSubModule: Added to cleanly handle submodules.