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'); } /**