Deduplicate embedded images, ref #628
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include "database/Release.hpp"
|
||||
#include "database/Session.hpp"
|
||||
#include "database/Track.hpp"
|
||||
#include "database/TrackEmbeddedImage.hpp"
|
||||
|
||||
namespace lms::scanner
|
||||
{
|
||||
@@ -40,6 +41,7 @@ namespace lms::scanner
|
||||
removeOrphanedLabels(context);
|
||||
removeOrphanedCountries(context);
|
||||
removeOrphanedDirectories(context);
|
||||
removeOrphanedTrackEmbeddedImages(context);
|
||||
}
|
||||
|
||||
void ScanStepRemoveOrphanedDbEntries::removeOrphanedClusters(ScanContext& context)
|
||||
@@ -90,6 +92,12 @@ namespace lms::scanner
|
||||
removeOrphanedEntries<db::Directory>(context);
|
||||
}
|
||||
|
||||
void ScanStepRemoveOrphanedDbEntries::removeOrphanedTrackEmbeddedImages(ScanContext& context)
|
||||
{
|
||||
LMS_LOG(DBUPDATER, DEBUG, "Checking orphaned embedded images in tracks...");
|
||||
removeOrphanedEntries<db::TrackEmbeddedImage>(context);
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
void ScanStepRemoveOrphanedDbEntries::removeOrphanedEntries(ScanContext& context)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user