Fix issue with channelById type error (object vs map) this was breaking scheduling manual DVR recordings.

This commit is contained in:
SergeantPanda 2026-02-18 15:16:33 -06:00
parent 34a24b2e44
commit 8a8df11b72

View file

@ -283,10 +283,10 @@ export default function TVChannelGuide({ startDate, endDate }) {
// Local map of channel id -> channel object for quick lookup
const channelById = useMemo(() => {
const map = {};
const map = new Map();
for (const ch of guideChannels) {
if (ch && ch.id !== undefined && ch.id !== null) {
map[ch.id] = ch;
map.set(ch.id, ch);
}
}
return map;