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
[interfaces/json-rpc] Allow VideoLibrary.Clean by directory #18562
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good apart from the minors.
437b155
to
aafc5fb
Compare
aafc5fb
to
c0e4bd4
Compare
Thanks for the changes. jenkins build this please |
Will this work also for |
I have not tested i have no addon ready to this, |
Description
Add
directory
parameter toVideoLibrary.Clean
, as done onVideoLibrary.Scan
Motivation and Context
there are two ways to remove items that no longer exist from the Kodi library
call single jsonRPC's (e.g.
VideoLibrary.RemoveEpisode
) for each file or clean the libraryThe first method (each call per file) is intensive when you have to delete hundreds of files, and have side effect to show loading screen (e.g. if you are doing the operation while watching a video)
The second method you do only one call, at the end of your addon operations, is very fast and easy to do because you do not need a separate job to collect the list of paths to remove.
Why add directory parameter:
How Has This Been Tested?
Tested on windows 10 with Jellyfin library items and netflix library items at same time
When i set VideoLibrary.Clean to netflix folder check only the netflix kodi library path
Another test is done on the issue referenced before, with nf+samba library source
Screenshots (if appropriate):
Types of change
Checklist: