From e55139069d547a257c610d9435ac6a5e64966bb4 Mon Sep 17 00:00:00 2001 From: Rob Lister Date: Thu, 6 Feb 2020 10:32:31 +0000 Subject: [PATCH] Update declarations to fix warnings in newer dokuwiki This plugin works on newer versions of Dokuwiki, (Release 2018-04-22a "Greebo") but generates warnings in the server log: FastCGI sent in stderr: "PHP message: PHP Warning: Declaration of syntax_plugin_cli::handle($match, $state, $pos, &$handler) should be compatible wither $handler) in /var/lib/dokuwiki/lib/plugins/cli/syntax.php on line 0" --- syntax.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/syntax.php b/syntax.php index c849ce0..af0151a 100644 --- a/syntax.php +++ b/syntax.php @@ -110,7 +110,7 @@ function postConnect() { /** * Handle the match */ - function handle($match, $state, $pos, &$handler){ + function handle($match, $state, $pos, Doku_Handler $handler) { switch ($state) { case DOKU_LEXER_ENTER : $args = substr($match, 4, -1); @@ -130,7 +130,7 @@ function handle($match, $state, $pos, &$handler){ /** * Create output */ - function render($mode, &$renderer, $data) { + function render($mode, Doku_Renderer $renderer, $data) { if($mode == 'xhtml'){ list($state, $match) = $data; switch ($state) {