Skip to content

Commit

Permalink
Fix parsing private vimeo links
Browse files Browse the repository at this point in the history
  • Loading branch information
chojnicki committed Aug 15, 2024
1 parent 34ac758 commit 27f5bef
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/VideoPlatformsParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -177,11 +177,10 @@ public function detectURL($url)
} else if (strpos($parsed_url['host'], 'vimeo.com') !== false) {
if (empty($parsed_url['path'])) return false;
$path = explode('/', $parsed_url['path']);
if (!is_numeric(end($path))) return false;

return [
'platform' => 'vimeo',
'id' => end($path)
'id' => implode('/', array_filter($path))
];
} else if (strpos($parsed_url['host'], 'cda.pl') !== false) {
if (strpos($parsed_url['path'], '/video/') === false) return false;
Expand Down

0 comments on commit 27f5bef

Please sign in to comment.