Skip to content

Commit

Permalink
Merge pull request #47 from bolt/hotfix/correct-path
Browse files Browse the repository at this point in the history
Make sure we use the correct path, on both Bolt 3.2 as well as 3.3
  • Loading branch information
GwendolenLynch authored Jul 20, 2017
2 parents 2c18a11 + 0eed7ce commit 2b20f46
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/LabelsExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
use Bolt\Controller\Zone;
use Bolt\Extension\SimpleExtension;
use Bolt\Menu\MenuEntry;
use Bolt\Version;
use Silex\Application;
use Symfony\Component\HttpFoundation\Request;

Expand Down Expand Up @@ -74,8 +75,13 @@ protected function registerBackendControllers()
{
$app = $this->getContainer();

$baseUrl = Version::compare('3.2.999', '<')
? '/extensions/labels'
: '/extend/labels'
;

return [
'extend/labels' => $app['labels.controller.backend'],
$baseUrl => $app['labels.controller.backend'],
];
}

Expand Down

0 comments on commit 2b20f46

Please sign in to comment.