2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-02-25 09:55:38 +00:00

MQTT2_DEVICE: fix devicetopic parsing (Forum #130965)

git-svn-id: https://svn.fhem.de/fhem/trunk@26860 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig 2022-12-16 08:13:49 +00:00
parent 3b8c84f450
commit f489864982

View File

@ -448,8 +448,8 @@ MQTT2_DEVICE_Attr($$)
} else {
my ($a, $h) = parseParams($param); #126679
foreach my $key (keys %{$h}) {
return "$key is not valid, must only contain a-zA-z0-9_"
if($key !~ m/[a-z0-9_]/);
return "$key is not valid, must only contain a-zA-Z0-9_"
if($key !~ m/^[a-zA-Z0-9_]+$/);
}
$hash->{".DT"} = $h;
}