From b5f0655ceaa8bfd2f480d0f015535498287e57cb Mon Sep 17 00:00:00 2001 From: Thomas Hochstein Date: Sun, 2 Sep 2018 15:53:08 +0200 Subject: [PATCH] [event_dsgvo_gdpr] Display plugin legal info. Currently, legal information for plugins is only shown when it had not been cached. As most plugin info will be cached, nothing's shown. We have to bypass the cache and query all installed plugins directly to make that work. Fixes #572. Signed-off-by: Thomas Hochstein --- serendipity_event_dsgvo_gdpr/ChangeLog | 1 + .../serendipity_event_dsgvo_gdpr.php | 7 +++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/serendipity_event_dsgvo_gdpr/ChangeLog b/serendipity_event_dsgvo_gdpr/ChangeLog index aecff944..b03b1fc2 100644 --- a/serendipity_event_dsgvo_gdpr/ChangeLog +++ b/serendipity_event_dsgvo_gdpr/ChangeLog @@ -1,3 +1,4 @@ +1.2.1: Really display legal information for plugins. 1.2.0: Add button to copy pricvacy draft in html 1.1.0: Set default value of commentform checkbox to false 1.0.7: Properly quit once the CSV dump is sent, and not embed this in HTML diff --git a/serendipity_event_dsgvo_gdpr/serendipity_event_dsgvo_gdpr.php b/serendipity_event_dsgvo_gdpr/serendipity_event_dsgvo_gdpr.php index 95c07416..9f63452a 100644 --- a/serendipity_event_dsgvo_gdpr/serendipity_event_dsgvo_gdpr.php +++ b/serendipity_event_dsgvo_gdpr/serendipity_event_dsgvo_gdpr.php @@ -23,7 +23,7 @@ class serendipity_event_dsgvo_gdpr extends serendipity_event $propbag->add('description', PLUGIN_EVENT_DSGVO_GDPR_DESC); $propbag->add('stackable', false); $propbag->add('author', 'Serendipity Team'); - $propbag->add('version', '1.2.0'); + $propbag->add('version', '1.2.1'); $propbag->add('requirements', array( 'serendipity' => '2.0', 'smarty' => '2.6.7', @@ -152,8 +152,7 @@ class serendipity_event_dsgvo_gdpr extends serendipity_event $classes = serendipity_plugin_api::enum_plugins(); foreach ($classes as $class_data) { - $pluginFile = serendipity_plugin_api::probePlugin($class_data['name'], $class_data['classname'], $class_data['pluginPath']); - $plugin =& serendipity_plugin_api::getPluginInfo($pluginFile, $class_data, 'event'); + $plugin =& serendipity_plugin_api::load_plugin($class_data['name']); if (is_object($plugin)) { // Object is returned when a plugin could not be cached. @@ -162,7 +161,7 @@ class serendipity_event_dsgvo_gdpr extends serendipity_event $legal = $bag->get('legal'); if (is_array($legal)) { - $out .= '

' . $class_data['classname'] . '

'; + $out .= '

' . $bag->get('name') . '

'; // "services" should list every service that a plugin connects to via a HTTP or other API interface, // and describe what each service does, and which data it gets.