use entry::element_of to set action parameter
This commit is contained in:
@@ -242,13 +242,8 @@ sub check_params {
|
||||
|
||||
my $checked = {};
|
||||
|
||||
#actions
|
||||
|
||||
if ( defined $params->{action} ) {
|
||||
if ( $params->{action} =~ /^(setLock|setRead|showComment)$/ ) {
|
||||
$checked->{action} = $params->{action};
|
||||
}
|
||||
}
|
||||
$checked->{action} = entry::element_of($params->{action},
|
||||
[ 'setLock', 'setRead', 'showComment', 'update', 'delete']);
|
||||
|
||||
#template
|
||||
my $template = '';
|
||||
|
||||
Reference in New Issue
Block a user