Skip to content

Commit 32a9b57

Browse files
authored
Merge pull request #494 from DieterHolvoet/issue-458
Add support for YouTube Shorts
2 parents 79ec23e + c2f76ef commit 32a9b57

File tree

4 files changed

+141
-147
lines changed

4 files changed

+141
-147
lines changed

scripts/update-oembed.php

+1-9
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,10 @@
1818
}
1919
}
2020

21-
//Add missing endpoints
22-
saveEndpoint('http://jsbin.com/oembed', ['output.jsbin.com/*']);
23-
saveEndpoint('https://api.crowdsignal.com/oembed', ['polldaddy.com/poll/*', 'poll.fm/*']);
24-
saveEndpoint('http://www.scribd.com/services/oembed/', ['www.scribd.com/document/*']);
25-
saveEndpoint('https://api.imgur.com/oembed', ['imgur.com/*', 'i.imgur.com/*']);
26-
saveEndpoint('https://www.youtube.com/oembed', ['*.youtube.com/playlist?*']);
27-
saveEndpoint('https://www.tiktok.com/oembed', ['*.tiktok.com/*']);
28-
2921
//Export the endpoints
3022
file_put_contents(
3123
dirname(__DIR__).'/src/resources/oembed.php',
32-
sprintf("<?php\ndeclare(strict_types = 1);\n\nreturn %s;\n", VarExporter::export($endpoints))
24+
sprintf("<?php\ndeclare(strict_types = 1);\n\nreturn %s;\n", VarExporter::export($endpoints, VarExporter::TRAILING_COMMA_IN_ARRAY))
3325
);
3426

3527
echo 'Endpoints saved'.PHP_EOL;

scripts/update-suffix.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
file_put_contents(
1212
dirname(__DIR__).'/src/resources/suffix.php',
13-
sprintf("<?php\ndeclare(strict_types = 1);\n\nreturn %s;\n", VarExporter::export(array_values($lines)))
13+
sprintf("<?php\ndeclare(strict_types = 1);\n\nreturn %s;\n", VarExporter::export(array_values($lines), VarExporter::TRAILING_COMMA_IN_ARRAY))
1414
);
1515

1616
echo 'Suffix saved'.PHP_EOL;

0 commit comments

Comments
 (0)