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

FULLY: Fixed version check bug

git-svn-id: https://svn.fhem.de/fhem/trunk@17632 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
zap 2018-10-28 09:49:59 +00:00
parent 702ee7aa34
commit e94ce46065
2 changed files with 11 additions and 4 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it. # Do not insert empty lines here, update check depends on it.
- bugfix: 89_FULLY: fixed version check bug
- feature: 74_AMADtaskerset: import with share link - feature: 74_AMADtaskerset: import with share link
- change: 42_AptToDate: change to package methode - change: 42_AptToDate: change to package methode
- bugfix: 74_XiaomiBTLESens: fix humidity code - bugfix: 74_XiaomiBTLESens: fix humidity code

View File

@ -1,6 +1,6 @@
############################################################################## ##############################################################################
# #
# 89_FULLY.pm 0.9 # 89_FULLY.pm 0.9.001
# #
# $Id$ # $Id$
# #
@ -35,7 +35,7 @@ sub FULLY_Abort ($);
sub FULLY_UpdateReadings ($$); sub FULLY_UpdateReadings ($$);
sub FULLY_Ping ($$); sub FULLY_Ping ($$);
my $FULLY_VERSION = "0.9"; my $FULLY_VERSION = "0.9.001";
my $FULLY_TIMEOUT = 4; my $FULLY_TIMEOUT = 4;
my $FULLY_POLL_INTERVAL = 3600; my $FULLY_POLL_INTERVAL = 3600;
my $FULLY_REQUIRED_VERSION = 1.27; my $FULLY_REQUIRED_VERSION = 1.27;
@ -532,8 +532,14 @@ sub FULLY_ProcessDeviceInfo ($$)
$parameters .= "|state=$rv"; $parameters .= "|state=$rv";
} }
elsif ($rn eq 'fully_version') { elsif ($rn eq 'fully_version') {
if ($rv =~ /^([0-9]\.[0-9]+).*/) {
my $cv = $1;
Log3 $name, 1, "FULLY: [$name] Version of fully browser is $rv. Version $FULLY_REQUIRED_VERSION is required." Log3 $name, 1, "FULLY: [$name] Version of fully browser is $rv. Version $FULLY_REQUIRED_VERSION is required."
if ($rv < $FULLY_REQUIRED_VERSION); if ($cv < $FULLY_REQUIRED_VERSION);
}
else {
Log3 $name, 2, "FULLY: [$name] Cannot detect version of fully browser.";
}
} }
$parameters .= "|$rn=$rv"; $parameters .= "|$rn=$rv";
} }