sjlevine / dokuwiki-alertbox

Bootstrap style alert boxes for DokuWiki
1 stars 2 forks source link

DokuWiki Release "Hogfather" #9

Open stormframe opened 4 years ago

stormframe commented 4 years ago

Fatal error: Declaration of syntax_plugin_alertbox::handle($match, $state, $pos, &$handler) must be compatible with dokuwiki\Extension\SyntaxPlugin::handle($match, $state, $pos, Doku_Handler $handler) in /lib/plugins/alertbox/syntax.php on line 0

EgerUS commented 4 years ago

Fix:

--- syntax.php  2020-07-10 00:34:06.855798328 +0200
+++ lib/plugins/alertbox/syntax.php  2020-07-10 00:27:17.249473783 +0200
@@ -19,7 +19,7 @@
     function postConnect() { $this->Lexer->addExitPattern('</alert>','plugin_alertbox'); }

-    function handle($match, $state, $pos, &$handler){
+    function handle($match, $state, $pos, Doku_Handler $handler){                                                                                                                                                                      
         switch ($state) {                                                                                                                                                                                                              
           case DOKU_LEXER_ENTER :                                                                                                                                                                                                      
                 // Default                                                                                                                                                                                                             
@@ -42,7 +42,7 @@                                                                                                                                                                                                                       
     }                                                                                                                                                                                                                                  

-    function render($mode, &$renderer, $data) {                                                                                                                                                                                        
+    function render($mode, Doku_Renderer $renderer, $data) {                                                                                                                                                                           
         if($mode == 'xhtml'){                                                                                                                                                                                                          
             list($state, $match) = $data;                                                                                                                                                                                              
             switch ($state) {