ReferenceError window is not defined

I have a local and global variable which have the same name; inside my function I want to assign my local variable to my global variable; but in Node, it gives me the following error:

[ReferenceError: window is not defined] My code is:

var config;
module.exports.myFunc = function(host, config, callback) {    
        window.config = config;
        .
        .
        .
        callback(data);
}

How can I assign my local variable to my global variable which has the same name?

Thanks