aboutsummaryrefslogtreecommitdiffstats
path: root/scraper/yt.php
diff options
context:
space:
mode:
authorlolcat <will@lolcat.ca>2025-01-03 22:22:30 -0500
committerlolcat <will@lolcat.ca>2025-01-03 22:22:30 -0500
commit4e968b4b1cca7a43ba98fdae655fed1eeea591f6 (patch)
treebe9a8d7448c81719aa71002b9779597ba9fdc784 /scraper/yt.php
parent81df52235c4f5e213c2ee705343b386db9f66d1b (diff)
youtube scraper fix
Diffstat (limited to 'scraper/yt.php')
-rw-r--r--scraper/yt.php27
1 files changed, 10 insertions, 17 deletions
diff --git a/scraper/yt.php b/scraper/yt.php
index 668b8f5..a27fd82 100644
--- a/scraper/yt.php
+++ b/scraper/yt.php
@@ -1209,15 +1209,16 @@ class yt{
$reel =
$reel
- ->reelItemRenderer;
+ ->shortsLockupViewModel;
array_push(
$this->out["reel"],
[
"title" =>
$reel
- ->headline
- ->simpleText,
+ ->overlayMetadata
+ ->primaryText
+ ->content,
"description" => null,
"author" => [
"name" => null,
@@ -1225,30 +1226,22 @@ class yt{
"avatar" => null
],
"date" => null,
- "duration" =>
- $this->textualtime2int(
- $reel
- ->accessibility
- ->accessibilityData
- ->label
- ),
- "views" =>
- $this->truncatedcount2int(
- $reel
- ->viewCountText
- ->simpleText
- ),
+ "duration" => null,
+ "views" => null,
"thumb" => [
"url" =>
$reel
->thumbnail
- ->thumbnails[0]
+ ->sources[0]
->url,
"ratio" => "9:16"
],
"url" =>
"https://www.youtube.com/watch?v=" .
$reel
+ ->onTap
+ ->innertubeCommand
+ ->reelWatchEndpoint
->videoId
]
);
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage