From e07abfa02a543f1ddc9515d039f3fe56f81b5b88 Mon Sep 17 00:00:00 2001 From: Ajay Bura <32841439+ajbura@users.noreply.github.com> Date: Mon, 7 Mar 2022 11:33:51 +0530 Subject: [PATCH] Add missing type --- src/domain/ViewModel.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/domain/ViewModel.ts b/src/domain/ViewModel.ts index 04fec86e..8b8581ae 100644 --- a/src/domain/ViewModel.ts +++ b/src/domain/ViewModel.ts @@ -58,9 +58,9 @@ export class ViewModel extends EventEmitter<{change return this._options[name]; } - observeNavigation(type: string, onChange: (value: true | string, type: string) => void) { + observeNavigation(type: string, onChange: (value: string | true | undefined, type: string) => void) { const segmentObservable = this.navigation.observe(type); - const unsubscribe = segmentObservable.subscribe((value: true | string) => { + const unsubscribe = segmentObservable.subscribe((value: string | true | undefined) => { onChange(value, type); }) this.track(unsubscribe);