2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-04-16 10:46:03 +00:00

98_DOIF.pm: DEF TPL_: now more than nine parameters allowed

git-svn-id: https://svn.fhem.de/fhem/trunk@22195 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
Damian 2020-06-18 16:38:55 +00:00
parent b790150954
commit d78f00d5f4

View File

@ -521,9 +521,9 @@ sub DOIF_TPL {
return "error: $err";
} elsif ($currentBlock ne "") {
my @param = SplitDoIf(',',$currentBlock);
for (my $j=0;$j<@param;$j++) {
my $p=$j+1;
$templ =~ s/\$$p/$param[$j]/g;
for (my $j=@param;$j>0;$j--) {
my $p=$j;
$templ =~ s/\$$p/$param[$j-1]/g;
}
}
$output.=($begin.$templ);
@ -2512,7 +2512,7 @@ DOIF_Notify($$)
} elsif ($dev->{NAME} !~ /$hash->{helper}{DEVFILTER}/) {
return "";
}
$eventa = deviceEvents($dev, AttrVal($pn, "addStateEvent", 0));
$eventas = deviceEvents($dev, 1);
delete ($hash->{helper}{DOIF_eventas});