mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-10 09:16:53 +00:00
fhem.pl: Fix ReplaceSetMagic bug (Forum #38276)
git-svn-id: https://svn.fhem.de/fhem/trunk@10315 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
53df67391e
commit
9d1e5cb245
@ -1542,6 +1542,7 @@ ReplaceSetMagic($$@) # Forum #38276
|
||||
my $hash = shift;
|
||||
my $nsplit = shift;
|
||||
my $a = join(" ", @_);
|
||||
my $oa = $a;
|
||||
|
||||
$a =~ s/\[([a-z0-9._]+):([A-z0-9._]+)\]/{
|
||||
my $x = ReadingsVal($1,$2,""); $x eq "" ? "[$1:$2]" : $x
|
||||
@ -1549,7 +1550,8 @@ ReplaceSetMagic($$@) # Forum #38276
|
||||
|
||||
$a =~ s/{\((.*)\)}/AnalyzePerlCommand($hash->{CL},$1,1)/eg;
|
||||
|
||||
return (undef, split(" ", $a, $nsplit));
|
||||
return (undef, @_) if($oa eq $a);
|
||||
return (undef, split(/ /, $a, $nsplit));
|
||||
}
|
||||
|
||||
#####################################
|
||||
|
Loading…
x
Reference in New Issue
Block a user