title: How to debug uncaught (in promise): EmptyError: no elements in sequence caused by router.navigate?
body: <p>I'm trying to implement a simple angular route</p>
  
  <pre><code>const appRoutes: Routes = [
     { path: ''        ,redirectTo: '/recipes', pathMatch: 'full'},
     { path: 'recipes'              , component: RecipesComponent},
     { path: 'recipes/:recipeName'  , component: RecipesComponent},
  ];
  </code></pre>
  
  <p>in some component that generates the list, i have a function that on click of a 
  updates state variable and routes, though I also have fetching mechanism subscriber happening on initialization. </p>
  
  <pre><code>  ngOnInit() {
      this.route.params
        .subscribe(
          (params: {Params}) =&gt; {
  
            this.selectedRecipe = this.findRecipeByName(params['recipeName']);  
          });
    }
  
  
     navRecipe(recipeName: string): void {
        let path = '/recipes/' + recipeName;
        this.selectedRecipe = this.findRecipeByName(recipeName);
        this.router.navigate([path]);
     }
  </code></pre>
  
  <p>But when I try to click on a link that reroutes to component with parameter I get the following:</p>
  
  <pre><code>core.js:1350 ERROR Error: Uncaught (in promise): EmptyError: no elements in sequence
  EmptyError: no elements in sequence
      at new EmptyError (EmptyError.js:28)
      at FirstSubscriber._complete (first.js:154)
      at FirstSubscriber.Subscriber.complete (Subscriber.js:122)
      at MergeMapSubscriber._complete (mergeMap.js:150)
      at MergeMapSubscriber.Subscriber.complete (Subscriber.js:122)
      at MapSubscriber.Subscriber._complete (Subscriber.js:140)
      at MapSubscriber.Subscriber.complete (Subscriber.js:122)
      at EmptyObservable._subscribe (EmptyObservable.js:83)
      at EmptyObservable.Observable._trySubscribe (Observable.js:172)
      at EmptyObservable.Observable.subscribe (Observable.js:160)
      at new EmptyError (EmptyError.js:28)
      at FirstSubscriber._complete (first.js:154)
      at FirstSubscriber.Subscriber.complete (Subscriber.js:122)
      at MergeMapSubscriber._complete (mergeMap.js:150)
      at MergeMapSubscriber.Subscriber.complete (Subscriber.js:122)
      at MapSubscriber.Subscriber._complete (Subscriber.js:140)
      at MapSubscriber.Subscriber.complete (Subscriber.js:122)
      at EmptyObservable._subscribe (EmptyObservable.js:83)
      at EmptyObservable.Observable._trySubscribe (Observable.js:172)
      at EmptyObservable.Observable.subscribe (Observable.js:160)
      at resolvePromise (zone.js:824)
      at resolvePromise (zone.js:795)
      at eval (zone.js:873)
      at ZoneDelegate.invokeTask (zone.js:425)
      at Object.onInvokeTask (core.js:4621)
      at ZoneDelegate.invokeTask (zone.js:424)
      at Zone.runTask (zone.js:192)
      at drainMicroTaskQueue (zone.js:602)
      at ZoneTask.invokeTask [as invoke] (zone.js:503)
      at invokeTask (zone.js:1540)
  </code></pre>