Fix incorrect handling of submodules
Merge pull request #51 from sharwell/submodules

Fix incorrect handling of submodules