title: Angular(2/4) modalService.close() is not working
body: <p>This is my code:</p>
  
  <pre class="lang-js prettyprint-override"><code>import { NgbModal } from '@ng-bootstrap/ng-bootstrap';`
  
      constructor(private http: Http, private route: ActivatedRoute,private router: Router, private modalService: NgbModal) { }
  
      editDocumentRow = function (documentId, modal) {
          this.http.get(ConstantComponent.url + '/documentmanagerapi/Get/' + documentId).map((res: Response) =&gt; res.json()).subscribe(data =&gt; {
          this.documentsRowDetails = data
          this.modalService.open(modal)
          this.modalService.close() // not working
      })
    }
  </code></pre>
  
  <p>I am trying to use  <code>this.modalService.close()</code> in a different function. But it's not even working in the same function where <code>this.modalService.open(modal)</code> is working perfectly.</p>
  
  <p>I am getting this error:
  <code>this.modalService.close is not a function</code></p>
  
  <p>Any suggestion what went wrong here?</p>