From 2ad43d2e1013c572a2a993b9c37149970a329f10 Mon Sep 17 00:00:00 2001 From: Marcel Folaron Date: Sat, 24 Aug 2024 15:50:23 -0400 Subject: [PATCH] Fixes to version management for plugins --- .idea/codeception.xml | 5 ++++- .idea/leantime-oss.iml | 3 +-- .idea/php.xml | 1 + .idea/phpspec.xml | 3 +++ app/Core/Exceptions/ExceptionHandler.php | 3 ++- app/Domain/Plugins/Models/MarketplacePlugin.php | 1 + app/Domain/Plugins/Services/Plugins.php | 1 + app/Plugins | 2 +- 8 files changed, 14 insertions(+), 5 deletions(-) diff --git a/.idea/codeception.xml b/.idea/codeception.xml index ab51ce992c..303b7bb313 100644 --- a/.idea/codeception.xml +++ b/.idea/codeception.xml @@ -3,6 +3,9 @@ - + \ No newline at end of file diff --git a/.idea/leantime-oss.iml b/.idea/leantime-oss.iml index ce06c9615c..e8783e0ff7 100644 --- a/.idea/leantime-oss.iml +++ b/.idea/leantime-oss.iml @@ -5,9 +5,8 @@ - - + diff --git a/.idea/php.xml b/.idea/php.xml index 03bacd9a75..372583aa0f 100644 --- a/.idea/php.xml +++ b/.idea/php.xml @@ -246,6 +246,7 @@ + diff --git a/.idea/phpspec.xml b/.idea/phpspec.xml index 1a29d65314..8eb6dafd6b 100644 --- a/.idea/phpspec.xml +++ b/.idea/phpspec.xml @@ -68,6 +68,9 @@ + + \ No newline at end of file diff --git a/app/Core/Exceptions/ExceptionHandler.php b/app/Core/Exceptions/ExceptionHandler.php index 651467e7aa..73a499b23c 100644 --- a/app/Core/Exceptions/ExceptionHandler.php +++ b/app/Core/Exceptions/ExceptionHandler.php @@ -29,6 +29,7 @@ use Throwable; use Whoops\Handler\HandlerInterface; use Whoops\Run as Whoops; +use Symfony\Component\Console\Application as ConsoleApplication; class ExceptionHandler implements ExceptionHandlerContract { @@ -583,7 +584,7 @@ protected function convertExceptionToArray(Throwable $e) */ public function renderForConsole($output, Throwable $e) { - app()->renderThrowable($e, $output); + (new ConsoleApplication())->renderThrowable($e, $output); } /** diff --git a/app/Domain/Plugins/Models/MarketplacePlugin.php b/app/Domain/Plugins/Models/MarketplacePlugin.php index a62b75de6e..a39f45f87d 100644 --- a/app/Domain/Plugins/Models/MarketplacePlugin.php +++ b/app/Domain/Plugins/Models/MarketplacePlugin.php @@ -26,6 +26,7 @@ class MarketplacePlugin implements PluginDisplayStrategy public array $reviews; public string $marketplaceId; public array $compatibility; + public string $version; public function getCardDesc(): string { diff --git a/app/Domain/Plugins/Services/Plugins.php b/app/Domain/Plugins/Services/Plugins.php index 3f4b925a11..9f210fc6a2 100644 --- a/app/Domain/Plugins/Services/Plugins.php +++ b/app/Domain/Plugins/Services/Plugins.php @@ -414,6 +414,7 @@ public function getMarketplacePlugins(int $page, string $query = ''): array ->set('vendorEmail', $plugin['vendor_email'] ?? '') ->set('startingPrice', '$' . ($plugin['price'] ?? '') . (! empty($plugin['sub_interval']) ? '/' . $plugin['sub_interval'] : '')) ->set('rating', $plugin['rating'] ?? '') + ->set('version', $plugin['version'] ?? '') ->get(); } } diff --git a/app/Plugins b/app/Plugins index 2f29af404f..91e9975356 160000 --- a/app/Plugins +++ b/app/Plugins @@ -1 +1 @@ -Subproject commit 2f29af404ffc39ba2055f99562eb7db1fd4f0341 +Subproject commit 91e99753561a366346579df0cafdb4d4960c8a6a