Added support for require.resolve() and require.cache