From 435913a1e5d8d00074813ec19383dca9246d0ecc Mon Sep 17 00:00:00 2001 From: lolcat Date: Sun, 1 Sep 2024 20:59:10 -0400 Subject: [PATCH] solofield thumbnail fix --- scraper/solofield.php | 39 ++++++++++++++++++++++++++++----------- 1 file changed, 28 insertions(+), 11 deletions(-) diff --git a/scraper/solofield.php b/scraper/solofield.php index f21ab38..edb7744 100644 --- a/scraper/solofield.php +++ b/scraper/solofield.php @@ -180,17 +180,34 @@ class solofield{ if(count($thumb) !== 0){ - $thumb = [ - "ratio" => "1:1", - "url" => - "https://solofield.net" . - $this->fuckhtml - ->getTextContent( - $thumb[0] - ["attributes"] - ["src"] - ) - ]; + $uri = + $this->fuckhtml + ->getTextContent( + $thumb[0] + ["attributes"] + ["src"] + ); + + if(stripos($uri, "now_printing") === false){ + + $thumb = [ + "ratio" => "1:1", + "url" => + "https://solofield.net" . + $this->fuckhtml + ->getTextContent( + $thumb[0] + ["attributes"] + ["src"] + ) + ]; + }else{ + + $thumb = [ + "ratio" => null, + "url" => null + ]; + } }else{ $thumb = [