Commit 8bd89c4b authored by Côme Chilliet's avatar Côme Chilliet

🚑 fix(template) Fix skipping empty dialog when using a template

It was only working when using the action icon and not when using the
 menu item.

issue #6076
parent ac6c008a
......@@ -57,7 +57,7 @@ class templateDialog
if (($this->target === NULL) &&
is_object($this->template) &&
(isset($_POST[$this->post_finish]) || isset($_GET[$this->post_finish]) || empty($this->template->getNeeded()))
(isset($_POST[$this->post_finish]) || isset($_GET[$this->post_finish]))
) {
$this->template->save_object();
return $this->handle_finish();
......@@ -81,6 +81,9 @@ class templateDialog
return FALSE;
} else {
$this->template->save_object();
if (empty($this->template->getNeeded())) {
return $this->handle_finish();
}
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment