From 674c7c0aad21f024cdfa12b3f90564a32ee22ae1 Mon Sep 17 00:00:00 2001 From: dante di domenico Date: Thu, 6 Mar 2025 16:34:50 +0100 Subject: [PATCH 1/2] fix: safely load plugin twig view --- src/Plugin.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Plugin.php b/src/Plugin.php index 395012e..799cbab 100644 --- a/src/Plugin.php +++ b/src/Plugin.php @@ -18,6 +18,7 @@ use Cake\Console\CommandCollection; use Cake\Core\BasePlugin; use Cake\Core\PluginApplicationInterface; +use Cake\Http\BaseApplication; /** * Plugin class for BEdita\WebTools. @@ -54,7 +55,11 @@ public function bootstrap(PluginApplicationInterface $app): void // Call parent to load bootstrap from files. parent::bootstrap($app); + assert($app instanceof BaseApplication); + // Load more plugins here - $app->addPlugin('Cake/TwigView'); + if (!$app->getPlugins()->has('Cake/TwigView')) { + $app->addPlugin('Cake/TwigView'); + } } } From 9ed036d68656c99db1095d745c8ccf4953012cb7 Mon Sep 17 00:00:00 2001 From: dante di domenico Date: Thu, 6 Mar 2025 16:42:46 +0100 Subject: [PATCH 2/2] chore: dist branch 5.x --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 35852fa..9e418ed 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -20,5 +20,5 @@ jobs: uses: bedita/github-workflows/.github/workflows/release.yml@v2 with: main_branch: 'master' - dist_branches: '["master","1.x"]' + dist_branches: '["master","5.x"]' version_bump: ${{ inputs.releaseType }}