mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-08 17:06:15 -08:00
fix(channel-list): handle null values in channelList input setter
Entire-Checkpoint: 033757b19995
This commit is contained in:
1 parent
7931127aa6
commit
87b2c509aa
1 file changed
+5
-4
+5
-4
@@ -84,10 +84,11 @@ export class ChannelListContainerComponent implements OnInit, OnDestroy {
|
||||
|
||||
@Input()
|
||||
set channelList(value: Channel[]) {
|
||||
this._channelList = value;
|
||||
this.channelListSignal.set(value);
|
||||
this.channelList$.next(value);
|
||||
this.fetchEpgForChannels(value);
|
||||
const safeValue = value ?? [];
|
||||
this._channelList = safeValue;
|
||||
this.channelListSignal.set(safeValue);
|
||||
this.channelList$.next(safeValue);
|
||||
this.fetchEpgForChannels(safeValue);
|
||||
}
|
||||
|
||||
/** Active playlist ID as signal */
|
||||
|
||||
Reference in new issue
Block a user