title: angular 4 cannot read property 'id' of undefined
body: <p>i'm trying to use angular 4 to call to a dummy web api, here is my component <br></p>
  
  <pre class="lang-js prettyprint-override"><code>export class AppComponent {
      title = 'app';
      url = 'https://api.ipify.org/?format=json';
      results: any;
  
      constructor(private http: Http) {
          this.getData().subscribe(data =&gt; {
              this.results = data.json();
          })
      }
  
      getData() {
          return this.http.get(this.url);
      }
  
  }
  </code></pre>
  
  <p><br>
  but when i try to display it i get the result but also a screen of error <br></p>
  
  <pre><code>ERROR TypeError: Cannot read property 'ip' of undefined
  </code></pre>
  
  <p>what i want to understand is why it is shown because after a split second the data is well displayed .</p>