Fix #169. Expose require members in the repl.

This fixes #169 by putting the require members onto the cwdRequire function
which is exposed to the repl scope.
This commit is contained in:
isaacs 2010-06-11 13:59:18 -07:00 committed by Ryan Dahl
parent 431e72cbe8
commit e65e6039a8

View File

@ -24,6 +24,9 @@ function cwdRequire (id) {
}
return require(id);
}
Object.keys(require).forEach(function (k) {
cwdRequire[k] = require[k];
});
function setScope (self) {
scope = {};