DeploymentLinkForm: ignore unreachable core

fixes #1966
This commit is contained in:
Thomas Gelf 2019-09-30 10:41:31 +02:00
parent 7a95f430bf
commit d45af31503

View File

@ -84,7 +84,13 @@ class DeploymentLinkForm extends DirectorForm
$this->setAttrib('class', 'inline');
$this->addHtml(Icon::create('wrench'));
try {
// As this is shown for single objects, ignore errors caused by an
// unreachable core
$target = $this->shouldWarnAboutBug7530() ? '_self' : '_next';
} catch (\Exception $e) {
$target = '_next';
}
$this->addSubmitButton($this->translate('Deploy'), [
'class' => 'link-button icon-wrench',
'title' => $msg,
@ -108,9 +114,13 @@ class DeploymentLinkForm extends DirectorForm
public function onSuccess()
{
try {
if ($this->skipBecauseOfBug7530()) {
return;
}
} catch (\Exception $e) {
// continue
}
$this->deploy();
}