mirror of
https://github.com/FreshRSS/FreshRSS.git
synced 2026-05-15 10:43:55 -04:00
* Fix extension freshrss_user_maintenance in actualize_script Follow-up of https://github.com/FreshRSS/FreshRSS/pull/3440 The hook was called before registering all the extensions for the current user * PHPStan Level 6 for extensions And remove 5-year old legacy format of enabled extensions < FreshRSS 1.11.1 * Fix multiple bugs in extensions * Minor typing * Don't change signature of methods supposed to be overridden * PHPStan Level 9 and compatibility Intelliphense * Set as final the methods not supposed to be overriden
12 lines
374 B
PHP
12 lines
374 B
PHP
<?php
|
|
class GoogleGroupsExtension extends Minz_Extension {
|
|
/** @return void */
|
|
public function init() {
|
|
$this->registerHook('check_url_before_add', array('GoogleGroupsExtension', 'findFeed'));
|
|
}
|
|
|
|
public static function findFeed(string $url): string {
|
|
return preg_replace('%^(https?://groups.google.com/forum)/#!forum/(.+)$%i', '$1/feed/$2/msgs/rss.xml', $url);
|
|
}
|
|
}
|