fix internal call to the module name resolver

Also, check arguments in the default module name resolver.