Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement Catch-up support #22

Merged
merged 5 commits into from
Jun 27, 2022
Merged

Implement Catch-up support #22

merged 5 commits into from
Jun 27, 2022

Conversation

Kevinjil
Copy link
Owner

@Kevinjil Kevinjil commented Jun 27, 2022

Use EPG information to create a Catch-up channel containing the programs aired during the supported TV archive duration of the configured Live TV channels.

Closes #17

/// <returns>IAsyncEnumerable{StreamInfo}.</returns>
public async IAsyncEnumerable<StreamInfo> GetLiveStreams([EnumeratorCancellation] CancellationToken cancellationToken)
{
Plugin plugin = Plugin.Instance;

Check notice

Code scanning / CodeQL

Local scope variable shadows member

Local scope variable 'plugin' shadows [StreamService.plugin](1).
Comment on lines +111 to +118
foreach (StreamInfo channel in channels)
{
// If the set is empty, include all channels for the category.
if (streams.Count == 0 || streams.Contains(channel.StreamId))
{
yield return channel;
}
}

Check notice

Code scanning / CodeQL

Missed opportunity to use Where

This foreach loop implicitly filters its target sequence [here](1) - consider filtering the sequence explicitly using '.Where(...)'.
@Kevinjil Kevinjil merged commit 68b1799 into master Jun 27, 2022
@Kevinjil Kevinjil deleted the feature/issue-17 branch June 27, 2022 07:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Question] Catch UP / Rewind?
1 participant