edit.php:

- add error message if $handler->init() fails without error message
  (indicates a bug in $handler->init())


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1630 a1433add-5e2c-0410-b055-b7f2511e0802
pull/2/head
Christian Boltz 12 years ago
parent 0cf9d7e53c
commit bf170f043b

@ -47,6 +47,10 @@ authentication_require_role($formconf['required_role']);
if ($edit != '' || $formconf['early_init']) {
if (!$handler->init($edit)) {
if (count($handler->errormsg) == 0) {
# should never happen and indicates a bug in $handler->init()
flash_error($handlerclass . "->init() failed, but didn't set any error message");
}
flash_error($handler->errormsg);
header ("Location: " . $formconf['listview']);
exit;

Loading…
Cancel
Save