Skip to content

Commit

Permalink
fix(rumble): fix guid bug (#4232)
Browse files Browse the repository at this point in the history
Remove tracking parameter in query to avoid feed readers to interpret these as new items
  • Loading branch information
dvikan authored Aug 23, 2024
1 parent b0674d7 commit c849576
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion bridges/RumbleBridge.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,19 @@ public function collectData()

$dom = getSimpleHTMLDOM($url);
foreach ($dom->find('ol.thumbnail__grid div.thumbnail__grid--item') as $video) {
$itemUrlString = self::URI . $video->find('a', 0)->href;
$itemUrl = Url::fromString($itemUrlString);

$item = [
'title' => $video->find('h3', 0)->plaintext,
'uri' => self::URI . $video->find('a', 0)->href,

// Remove tracking parameter in query string
'uri' => $itemUrl->withQueryString(null)->__toString(),

'author' => $account . '@rumble.com',
'content' => defaultLinkTo($video, self::URI)->innertext,
];

$time = $video->find('time', 0);
if ($time) {
$publishedAt = new \DateTimeImmutable($time->getAttribute('datetime'));
Expand Down

0 comments on commit c849576

Please sign in to comment.