在以下情况下,我将如何访问父函数“var”变量(我只能编辑重置函数的定义):
_.bind(function(){
var foo = 5;
var reset = function(){
foo = 6; //this changes foo,
bar = 7; //**I want this to add another "var", so I don't pollute global scope
}
reset();
console.log(foo); //6
console.log(bar); //7
}, window);