ariatemplates/noder-js — pull request #18 by divdavem (2014-06-26 09:25:27+00:00)
Title: Removing module.parent and module.children to avoid memory leaks.

To unload a module, it should be sufficient to do: `delete require.cache[modulePath]`.

It is not very intuitive to have to do:
```js
var moduleToUnload = require.cache[modulePath];
var parentChildren = moduleToUnload.parent.children;
var index = parentChildren.indexOf(moduleToUnload);
parentChildren.splice(index, 1);
delete require.cache[modulePath];
```

Moreover, even if node.js [provides this feature](http://nodejs.org/api/modules.html#modules_module_parent), it is not very useful to have `module.parent` and `module.children`, so let's remove them to avoid any leak problem.