aboutsummaryrefslogtreecommitdiffstats
path: root/scraper/solofield.php
diff options
context:
space:
mode:
authorlolcat <will@lolcat.ca>2024-09-01 20:59:10 -0400
committerlolcat <will@lolcat.ca>2024-09-01 20:59:10 -0400
commit435913a1e5d8d00074813ec19383dca9246d0ecc (patch)
treea49a9a44fb53a0d1f5d44e9c76d7d7a35e82028e /scraper/solofield.php
parente4f94c43dbb2bbde6539ffd1d0eb472b4359c6bd (diff)
solofield thumbnail fix
Diffstat (limited to 'scraper/solofield.php')
-rw-r--r--scraper/solofield.php39
1 files 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 = [
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage