HostsController: fix issue with PHP 5.4

refs #1281
This commit is contained in:
Thomas Gelf 2017-11-10 14:20:33 +01:00
parent 6be7daf36a
commit 44c2a1b7db
1 changed files with 4 additions and 1 deletions

View File

@ -29,6 +29,9 @@ class HostsController extends ObjectsController
$url = clone($this->getRequest()->getUrl()); $url = clone($this->getRequest()->getUrl());
$url->setPath('director/hosts/addservice'); $url->setPath('director/hosts/addservice');
$urlSet = clone($url);
$urlSet->setPath('director/hosts/addserviceset');
parent::editAction(); parent::editAction();
$this->actions()->add(Link::create( $this->actions()->add(Link::create(
@ -38,7 +41,7 @@ class HostsController extends ObjectsController
['class' => 'icon-plus'] ['class' => 'icon-plus']
))->add(Link::create( ))->add(Link::create(
$this->translate('Add Service Set'), $this->translate('Add Service Set'),
clone($url)->setPath('director/hosts/addserviceset'), $urlSet,
null, null,
['class' => 'icon-plus'] ['class' => 'icon-plus']
)); ));