From 2c0ace4500845525f94319ee908ffe797f374568 Mon Sep 17 00:00:00 2001 From: billz Date: Wed, 25 Dec 2024 18:59:49 -0800 Subject: [PATCH] Fix for getUserPlugins, add installed btn --- src/RaspAP/Plugins/PluginInstaller.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/RaspAP/Plugins/PluginInstaller.php b/src/RaspAP/Plugins/PluginInstaller.php index 9f50321a..3157e3fe 100644 --- a/src/RaspAP/Plugins/PluginInstaller.php +++ b/src/RaspAP/Plugins/PluginInstaller.php @@ -61,12 +61,11 @@ class PluginInstaller $installed = false; foreach ($installedPlugins as $plugin) { - if (str_contains($plugin, $plugins['manifest']['namespace'])) { + if (str_contains($plugin, $manifest['namespace'])) { $installed = true; break; } } - $plugins[] = [ 'manifest' => $manifest, 'installed' => $installed @@ -427,7 +426,9 @@ class PluginInstaller $manifest = htmlspecialchars(json_encode($plugin['manifest']), ENT_QUOTES, 'UTF-8'); $installed = $plugin['installed']; if ($installed === true ) { - $status = 'Installed'; + $button = ''; } else { $button = '