mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-16 10:46:03 +00:00
fhem.pl: restricting eventMap regexp range with \b (Forum #26922)
git-svn-id: https://svn.fhem.de/fhem/trunk@6589 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
b3e0d066f2
commit
4f6d110275
@ -3204,8 +3204,8 @@ ReplaceEventMap($$$)
|
|||||||
my ($re, $val, $modifier) = split(":", $rv, 3);
|
my ($re, $val, $modifier) = split(":", $rv, 3);
|
||||||
next if(!defined($val));
|
next if(!defined($val));
|
||||||
if($dir) { # event -> GivenName
|
if($dir) { # event -> GivenName
|
||||||
if($str =~ m/$re/) {
|
if($str =~ m/\b$re\b/) {
|
||||||
$str =~ s/$re/$val/;
|
$str =~ s/\b$re\b/$val/;
|
||||||
$changed = 1;
|
$changed = 1;
|
||||||
last;
|
last;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user