title: exports return null before executing mongodb save when i call it from another controller?
body: <p>I have to call one controller function from another, but other function is not returning a proper value.
  I called a function from one controller in line 'a',line 'b' is another controller.but inside forEach loop when it comes to line 'c', its not executing inside code instead it return null before executing the code from line 'd'.</p>
  
  <pre><code>a. var invoiceItemResp = InvoiceItemController.createInvoiceItems(itemList, doc.id);
  
  b. exports.createInvoiceItems = (itemList, invoiceId) =&gt; {
      var counter = 0;
      var success = false;
      itemList.forEach(element =&gt; {
          var invoiceItem = new InvoiceItem({
              _id: new mongoose.Types.ObjectId(),
              invoice_id: invoiceId,
              item: element.item,
              amount: element.amount
          });
  c.        invoiceItem.save((err, doc) =&gt; {
  d.            if(!err){
                  ++counter;
                  if(counter == itemList.length){
                      response = {
                          "message": "success"
                      }
                      return response;
                  }
              }else{
                  response = {
                      "message": "failed"
                  }
                  return response;
              }
          });
      }); 
  }
  </code></pre>