PERL WARNING: Argument "er" isn't numeric in array element at ./FHEM/72_FRITZBOX

Begonnen von marc2, 11 April 2016, 20:34:39

Vorheriges Thema - Nächstes Thema

marc2

Moin !

Das passiert bei mir bei jedem readout, weil $readout an dieser Stelle nicht numerisch ist. Die Prüfung
auf einen zulässigen numerischen Wert beseitigt das Problem:

   elsif ($format eq "mohtype") {
      if ($readout =~ /^[012]$/) {
        $readout = $mohtype[$readout] if defined $mohtype[$readout];
      }
      $readout = "" if $readout eq "er";
   }


Gruß, Marc