From 17570699abb775e26adbd3233462715ffaabf005 Mon Sep 17 00:00:00 2001 From: wolfgang Date: Sun, 3 Mar 2024 11:55:49 +0100 Subject: [PATCH] =?UTF-8?q?little=20fixes=20(php=208=20constructors,=20ign?= =?UTF-8?q?ore=20missing=20subfeed=20title)=20-=20works=20for=20me=20with?= =?UTF-8?q?=20dokuwiki=202024-02-06a=20=E2=80=9CKaos=E2=80=9D=20&=20php=20?= =?UTF-8?q?8.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- action.php | 2 +- admin.php | 2 +- helper.php | 2 +- syntax/feed.php | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/action.php b/action.php index 633590f..83a46ad 100755 --- a/action.php +++ b/action.php @@ -21,7 +21,7 @@ function register(Doku_Event_Handler $controller) { 'process_feed'); } - function action_plugin_news() { + function __construct() { global $newsUpdated; $this->helper = $this->loadHelper('news', true); } diff --git a/admin.php b/admin.php index 93c8e51..4e04aae 100755 --- a/admin.php +++ b/admin.php @@ -22,7 +22,7 @@ class admin_plugin_news extends DokuWiki_Admin_Plugin { var $subfeed_selected = 0; var $subfeed_name = ""; - function admin_plugin_news() { + function __construct() { $this->helper =& plugin_load('helper', 'news'); if($_REQUEST['subfeeds'] != 'NotSet') { $this->helper->setSubFeed($_REQUEST['subfeeds']); diff --git a/helper.php b/helper.php index e04e090..fa296ca 100755 --- a/helper.php +++ b/helper.php @@ -52,7 +52,7 @@ function pageUpdated(){ function setUpdate($ar = null){ if($ar) { $this->header = $ar[0]; - $this->sub_feed = trim($ar[1]); + $this->sub_feed = trim($ar[1] ?? ""); } $this->wasUpdated = true; diff --git a/syntax/feed.php b/syntax/feed.php index 1b6859a..c92f9cf 100755 --- a/syntax/feed.php +++ b/syntax/feed.php @@ -19,7 +19,7 @@ class syntax_plugin_news_feed extends DokuWiki_Syntax_Plugin { var $helper; var $is_news_mgr; - function syntax_plugin_news_feed() { + function __construct() { $this->helper =& plugin_load('helper', 'news'); } /**