title: How to add addional logic before promise
body: <p>I use the following code which works OK, now I need to add to it before the readFileAsync another method which query the Dir, my question is how to do that ?</p>
  
  <p>this is currently the code which is working</p>
  
  <pre><code>    var filePath = path.join(__dirname, '../userpath');
  
      return fs.readFileAsync(filePath, 'utf8')
          .then(pars.getEx.bind(null, 'user'))
          .then(process.bind(null, 'exec'))
          .then(function (result) {
              return result.stdout;
          }, function (error) {
              return error;
          });
  </code></pre>
  
  <p>Now I need to add some process before which is like following:
  which should now return the path to the readfileAsync (the -relFilePath)
  How should I do that </p>
  
  <pre><code>var filePath = path.join(__dirname, '../../../../employess');
  
  fs.readdir(filePath, function (err, files) {
      files.forEach(function (file) {
          if (file.indexOf('emp1') === 0) {
  
              // this should be returned 
              var relFilePath = filePath + '/' + file + '/unpath.txt';
  
              console.log(relFilePath);
              fs.readFile(relFilePath,'utf8', function read(err, data) {
                  if (err) {
                      throw err;
                  }
                  console.log(data);
              });
          }
      });
  </code></pre>
  
  <p>});</p>
  
  <p>I use bluebird...</p>