From fd1280e1232a2664a4364e655ef0049d19f01346 Mon Sep 17 00:00:00 2001 From: vt-idiot <81622808+vt-idiot@users.noreply.github.com> Date: Tue, 4 Jun 2024 09:10:26 -0400 Subject: [PATCH] scraper: fix filenames when scraping a single scene from SLR (#1738) Forces siteID to populate in filename when scraping a single scene --- pkg/scrape/slrstudios.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkg/scrape/slrstudios.go b/pkg/scrape/slrstudios.go index cefe64dd0..414a5f299 100644 --- a/pkg/scrape/slrstudios.go +++ b/pkg/scrape/slrstudios.go @@ -415,6 +415,10 @@ func appendFilenames(sc *models.ScrapedScene, siteID string, filenameRegEx *rege // Only shown for logged in users so need to generate them // Format: SLR_siteID_Title__SceneID__<180/360>.mp4 if !isTransScene { + // Force siteID when scraping individual scenes without a custom site + if siteID == "" { + siteID = gjson.Get(JsonMetadataA, "paysite.name").String() + } viewAngle := gjson.Get(JsonMetadataA, "viewAngle").String() projSuffix := "_LR_180.mp4" if viewAngle == "190" || viewAngle == "200" || viewAngle == "220" {