Angular 2 service subscription not subscribing to my variable
<p>My service is returning an array of objects, I’m trying to subscribe the response to my local variable “destinations”. Here is my code:</p>

<pre><code>export class Component implements OnInit {

  destinations = [];

  constructor(public myService: MyService) {
  }

  ngOnInit() {
    this.myService.getDestinations()
        .subscribe(data =&gt; {
          destinations = data
       });
  }

}
</code></pre>