title: Async method pushes a promise inside of an object instead of a value
body: <p>I was trying to solve one problem for sometime, and did research on stack-overflow but cant seem to be able to find any solution that would actually help me in achieving the result that I need to come to. I'm trying to assign an array of objects inside of an array, but instead of getting a value I get "Promise".</p>
  
  <pre><code>async function groupsCollections() {
      mongo.connect(config.mongoURI, (err, client) =&gt; {
          if (err) {
              console.error(err)
              return
          }
          const testFolder = './groupCollections';
          let s = fs.readdirSync(testFolder)
          let combine = [];
          // going into each directory (Groups)
          s.forEach(file =&gt; {
              let tes = fs.readdirSync(`${testFolder}/${file}`)
              let ad = tes.map(el =&gt; {
                  let see = readFileAsync(`${testFolder}/${file}/${el}`, { encoding: 'utf8' }).then((text) =&gt; {
                      let jsonFile = JSON.parse(text)
                      return jsonFile;
                  })
                      .catch((err) =&gt; {
                          console.log('ERROR:', err);
                      });
                  return see
              })
              combine.push({ groupName: file, collections: ad })
          })
      })
  }
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/47HBH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/47HBH.png" alt="enter image description here"></a></p>
  
  <p>What should i change in my code, so that instead of Promises you would actually see values ? I was trying to solve this problem for hours but cant seem to find any other better solutions, so decided to come here and hope someone can guide me for the sake of a better solution to achieve the desired results.</p>
  
  <p>Would really appreciate any assistance.</p>