on invalid proceed method in call to editSave, warn and recover rather than run time error
This commit is contained in:
parent
59ce3b3fd6
commit
9a45ff4b91
3 changed files with 37 additions and 3 deletions
|
|
@ -3162,9 +3162,14 @@ sub www_editSave {
|
|||
elsif ($proceed ne "") {
|
||||
my $method = "www_".$session->form->process("proceed");
|
||||
$session->asset($object);
|
||||
return $session->asset->$method();
|
||||
if( $session->asset->can($method) ) {
|
||||
return $session->asset->$method();
|
||||
}
|
||||
else {
|
||||
$session->log->warn("proceed method of $method specified but that method doesn't exist in " . ref($session->asset));
|
||||
# else fall through to the default handling below
|
||||
}
|
||||
}
|
||||
|
||||
$session->asset($object->getContainer);
|
||||
return $session->asset->www_view;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue