title: making event in module.exports functions
body: <p>I'm trying to make a module with an even that I could call from the index file (after a require).
  My code includes <code>var events = require("events");</code> and I've wrote only the tricky part here.</p>
  
  <h2>index.js:</h2>
  
  <pre><code>var reqw = require('./module.js');
  reqw.on('data', function(d) {
      console.log(d);
  });
  </code></pre>
  
  <h2>module.js:</h2>
  
  <pre><code>module.exports = {
      listaccts: function() {
          events.EventEmitter.call(this);
      }
  }
  util.inherits(exports.listaccts, events.EventEmitter);
  exports.listaccts.prototype.listme = function() {
      thisList = this;
      var req = https.request(requestOptions, function(res) {
          res.on('data', function(chuck) {
              store = chuck;
          });
          res.on('end', function(d) {
              thisList.emit("data", store.toString());
          });
      });
  }
  </code></pre>
  
  <p>Searched the whole we and yet to find a proper answer..</p>