title: Loosing context inside the callback
body: <p>I have a service which has this method:</p>
  
  <pre><code>public register(user, successCallback, errorCallback) {
      const httpHeaders = new HttpHeaders({
        'Content-Type' : 'application/json',
      });
  
      return this.httpClient.post(`${this.apiURL}/users/register`, user, { observe: 'response', headers: httpHeaders }).subscribe(
          (response) =&gt; successCallback(response),
          (error) =&gt; errorCallback(error)
      );
    }
  </code></pre>
  
  <p>I am calling that service method from a component </p>
  
  <pre><code>this.apiService.register(this.user, function(response) {
          this.router.navigateByUrl('/login', { state: { registered: true } })
        }, function(error) {
          console.log(error);
        });
  </code></pre>
  
  <p>On the line where I call <code>this.router.navigateByUrl</code> I am getting this error:</p>
  
  <p><code>ERROR TypeError: Cannot read property 'router' of undefined</code></p>
  
  <p>I understand that this is not defined, but I am not sure what is the proper way of using this within a callback.</p>
  
  <p>Any advice?</p>