mirror of
https://github.com/iptv-org/iptv.git
synced 2026-11-25 17:51:16 +02:00
fix: keep the main feed when a streams:edit request gives only the channel ID
The edit template accepts a Stream ID made of the channel ID alone. In that case updateWithIssue set the feed to undefined and updateTvgId wrote tvg-id="<channel_id>" with no feed. playlist:generate only keeps streams with an explicit feed, so the edited stream silently dropped out of index.m3u and every grouped playlist until someone ran playlist:format. This happened for #59575 (ATM Rozrywka REWORK) and earlier for Qazaqstan HD. Fill in the channel's main feed, the same feed the SDK's getId() and the add path already resolve to.
This commit is contained in:
@@ -52,7 +52,7 @@ export class Stream extends sdk.Models.Stream {
|
||||
|
||||
if (channelId) {
|
||||
this.channel = channelId
|
||||
this.feed = feedId
|
||||
this.feed = feedId || this.getChannel()?.getMainFeed()?.id || null
|
||||
this.updateTvgId().updateTitle().updateFilepath()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user