Label for regular expression errors on rule save.
This commit is contained in:
parent
9a5127fb7e
commit
c0adc273aa
2 changed files with 8 additions and 0 deletions
|
|
@ -230,6 +230,8 @@ sub www_editRuleSave {
|
|||
$session->log->warn("Error: $@");
|
||||
my $error = $@;
|
||||
$error =~ s/at \S+?\.pm line \d+.*$//;
|
||||
my $i18n = WebGUI::International->new($session, 'PassiveAnalytics');
|
||||
$error = join ' ', $i18n->get('Regular Expression Error:'), $error;
|
||||
return www_editRule($session, $error);
|
||||
}
|
||||
my $ruleId = $form->get('ruleId');
|
||||
|
|
|
|||
|
|
@ -123,6 +123,12 @@ home\?func=match, or<br />
|
|||
context => q|Button label to begin analyzing the logs.|
|
||||
},
|
||||
|
||||
'Regular Expression Error:' => {
|
||||
message => q|Regular Expression Error:|,
|
||||
lastUpdated => 0,
|
||||
context => q|Error displayed when a user enters in a bad regular expression. This label will be followed by the error from perl.|
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue