Closed kevinpapst closed 6 months ago
Help to test welcome (I am not a user myself), and optionally to finalise the light code upgrade (e.g. [ ]
instead of array()
, <?= $x ?>
instead of <?php echo $x; ?>
, ...) but that is not urgent.
Ping @ImAReplicant Let's merge the latest changes if there is any missing from https://framagit.org/ImAReplicant/freshrss-youtube
Updated it yesterday. Didn't notice any issues.
Hello, I've been browsing the various topics about the youtube extension and there seems to be a misunderstanding about the fork I made.
I never wanted to steal @kevinpapst's work, in fact I had opened an issue to ask if I could integrate the fork (https://github.com/FreshRSS/Extensions/issues/133#issue-1204483674). I thought at the time that the extension was no longer maintained. I may have done it clumsily and I really apologize for that.
The changes I've made concern peertube videos, because without my changes peertube videos wouldn't be integrated.
In extension.php file,
line 136 :
if (preg_match('#^https?://www\.youtube\.com/watch\?v=|/videos/watch/[0-9a-f-]{36}$#', $link) !== 1) {
to
if (preg_match('#^https?://www\.youtube\.com/watch\?v=|/w/[0-9a-zA-Z]{22}$#', $link) !== 1) {
line 177 :
$url = str_replace('/watch', '/embed', $link);
to
$url = str_replace('/w', '/videos/embed', $link);
As for the rest of the changes, it was an attempt to modify the display of the peertube description, but it doesn't seem to work anymore. Indeed, the description is displayed in a rather strange way:
Sorry again for this misunderstanding and the problems it has caused.
Thanks for your explanation @ImAReplicant
From my end this is ready for merge, as @pax0707 confirmed that the current version works.
Let's do the Peertube (how many people use that?) integration either in its own extension or at least in second PR.
Could you please update https://github.com/FreshRSS/Extensions/blob/master/repositories.json accordingly?
Done
Thanks for accepting the extension!
See #216
Dear Reviewer I do not have a running FreshRSS installation for testing. The 8+ year old codebase was upgraded blindly to latest FreshRSS and "modern" PHP style, especially the code regarding user configuration handling needs testing. In other words: install before merge 😁