X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=plugins%2Fdemo_plugin%2Fdemo_plugin.php;h=bdbc719bc778c98c4a2396e8dc1049ecc20a26eb;hb=a0ab3c3f68ed3bca7d218e6e5847820b82b086ca;hp=b80a2b6d5175bfb57d8dcf9774c4336357807c5b;hpb=0926d263902c184bd4f4c2036cb8ee90f81c5060;p=github%2Fshaarli%2FShaarli.git diff --git a/plugins/demo_plugin/demo_plugin.php b/plugins/demo_plugin/demo_plugin.php index b80a2b6d..bdbc719b 100644 --- a/plugins/demo_plugin/demo_plugin.php +++ b/plugins/demo_plugin/demo_plugin.php @@ -73,7 +73,6 @@ function hook_demo_plugin_render_header($data) { // Only execute when linklist is rendered. if ($data['_PAGE_'] == Router::$PAGE_LINKLIST) { - // If loggedin if ($data['_LOGGEDIN_'] === true) { /* @@ -378,17 +377,13 @@ function hook_demo_plugin_render_daily($data) // Manipulate columns data - foreach ($data['cols'] as &$value) { - foreach ($value as &$value2) { - $value2['formatedDescription'] .= ' ಠ_ಠ'; - } + foreach ($data['linksToDisplay'] as &$value) { + $value['formatedDescription'] .= ' ಠ_ಠ'; } // Add plugin content at the end of each link - foreach ($data['cols'] as &$value) { - foreach ($value as &$value2) { - $value2['link_plugin'][] = 'DEMO'; - } + foreach ($data['linksToDisplay'] as &$value) { + $value['link_plugin'][] = 'DEMO'; } return $data; @@ -452,8 +447,7 @@ function hook_demo_plugin_render_feed($data) foreach ($data['links'] as &$link) { if ($data['_PAGE_'] == Router::$PAGE_FEED_ATOM) { $link['description'] .= ' - ATOM Feed' ; - } - elseif ($data['_PAGE_'] == Router::$PAGE_FEED_RSS) { + } elseif ($data['_PAGE_'] == Router::$PAGE_FEED_RSS) { $link['description'] .= ' - RSS Feed'; } }