title: Second .then() on promise is getting called with data as undefined
body: <p>I have a function in a service called accountManager that returns a promise seen below:</p>
  
  <p>The .then() on this promise fires and prints out the response like intended. </p>
  
  <pre><code>  signIn(email:String,password:String):Promise&lt;any&gt;{
      return this.http.post('http://localhost:3000/api/signin',JSON.stringify({
        "email": email,
        "password": password
      }),{headers: this.headers})
        .toPromise()
        .then(res =&gt; {
        //**This is defined**
          console.log(res);
        })
    }
  </code></pre>
  
  <p>The issue arises when I am in another class that uses this signIn method. The response inside the promise is now null. When I omit the promise from the function itself the returned promise's .then() has a value for the response.   </p>
  
  <pre><code>if (this.loginForm.valid === true){
    this.accountManager.signIn(this.email,this.password)
      .then(response =&gt;{
  
      //**This .then has an undefined response when added on to the promise returned from the signIn function.**
  
        let body = JSON.parse(response._body)
  
        if (body.payload.success === true){
          this.router.navigate(['/']);
        }else{
          this.signInError = true;
        }
    })
      .catch(error=&gt;{
        this.signInError = true;
      })
  </code></pre>
  
  <p>Does anyone know why the promise .then() contains a value when the promise is being returned but the promise that is given by the return does not have a value in it's .then()? I would be happy to clarify if anything is confusing. Thanks :)</p>