title: Node JS call a "local" function within module.exports
body: <p>How do you call a function from within another function in a module.exports declaration?</p>
  
  <p>I have MVC structure node js project and a controller called TestController.js. I want to access method within controller, but using <code>this</code> keyword gives below error:</p>
  
  <blockquote>
    <p>cannot call method getName of undefined</p>
  </blockquote>
  
  <pre><code>"use strict"
  module.exports = {
      myName : function(req, res, next) {
          // accessing method within controller
          this.getName(data);
      },
  
      getName : function(data) {
          // code
      }
  }
  </code></pre>
  
  <p>How do I access methods within controller?</p>