From b82f9d3546844ca308e3c1d45e0d2adc0263d41c Mon Sep 17 00:00:00 2001 From: Leon Styhre Date: Mon, 7 Aug 2023 23:32:14 +0200 Subject: [PATCH] When an invalid media file is detected by the scraper, the media type is now included in the error message --- es-app/src/scrapers/Scraper.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/es-app/src/scrapers/Scraper.cpp b/es-app/src/scrapers/Scraper.cpp index 0d7f8a903..c9c6c20ba 100644 --- a/es-app/src/scrapers/Scraper.cpp +++ b/es-app/src/scrapers/Scraper.cpp @@ -308,7 +308,6 @@ MDResolveHandle::MDResolveHandle(const ScraperSearchResult& result, // If the image is cached already as the thumbnail, then we don't need // to download it again, in this case just save it to disk and resize it. if (mResult.thumbnailImageUrl == it->fileURL && mResult.thumbnailImageData.size() > 0) { - // This is just a temporary workaround to avoid saving media files to disk that // are actually just containing error messages from the scraper service. The // proper solution is to implement file checksum checks to determine if the @@ -557,7 +556,7 @@ void MediaDownloadHandle::update() } if (imageFormat == FIF_UNKNOWN) { - setError("The file \"" + Utils::FileSystem::getFileName(mSavePath) + + setError("The " + mMediaType + " file \"" + Utils::FileSystem::getFileName(mSavePath) + "\" returned by the scraper seems to be invalid as it's less than " + "350 bytes in size", true);