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

Add IListingsManager Service #10981

Merged
merged 4 commits into from
Feb 20, 2024
Merged

Conversation

barronpm
Copy link
Member

@barronpm barronpm commented Feb 8, 2024

Changes
Adds IListingsManager service to manage listings providers and map their channels to tuner channels

src/Jellyfin.LiveTv/Listings/ListingsManager.cs Outdated Show resolved Hide resolved
src/Jellyfin.LiveTv/Listings/ListingsManager.cs Outdated Show resolved Hide resolved
src/Jellyfin.LiveTv/Listings/ListingsManager.cs Outdated Show resolved Hide resolved
src/Jellyfin.LiveTv/Listings/ListingsManager.cs Outdated Show resolved Hide resolved
src/Jellyfin.LiveTv/Listings/ListingsManager.cs Outdated Show resolved Hide resolved
src/Jellyfin.LiveTv/Listings/ListingsManager.cs Outdated Show resolved Hide resolved
/// <param name="validateLogin">A value indicating whether to validate login.</param>
/// <param name="validateListings">A value indicating whether to validate listings..</param>
/// <returns>Task.</returns>
Task<ListingsProviderInfo> SaveListingProvider(ListingsProviderInfo info, bool validateLogin, bool validateListings);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we append Async to these function names while we're moving them?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally I don't add the Async suffix unless there's a sync overload, but if we want to establish that as a convention we can do that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMO we should, makes it easier to see when a Task isn't properly awaited during code review

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do analyzers/warnings not cover that already? I would expect build to fail if someone didn't await a method like that

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They should, but in the past things have slipped through

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alright, in that case I have one more queued PR for this sort of refactoring, then I can make a PR that applies that suffix everywhere in LiveTV

@crobibero crobibero merged commit 31715c6 into jellyfin:master Feb 20, 2024
23 checks passed
@barronpm barronpm deleted the livetv-listingsmanager branch February 21, 2024 14:40
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.

None yet

4 participants