Better handling of sub-modules