[core] Fix "You provided 'null' where a stream was expected"

This commit is contained in:
devlikepro committed 2025-07-20 14:06:58 +07:00
1 parent e57cc2587c
commit 44a5ada162
1 file changed
+2 -1
+2 -1
View File
@@ -24,7 +24,8 @@ export class SwitchObservable<T> extends Observable<T> {
}
switch(newObservable$: Observable<T>) {
this.subject$.next(newObservable$);
// If newObservable$ is null or undefined, use EMPTY instead
this.subject$.next(newObservable$ || EMPTY);
}
complete() {