Skip to content

Commit

Permalink
Merge pull request #486 from hplato/analog_sensor
Browse files Browse the repository at this point in the history
Added a white space in the sensor matching to prevent TempSpare10 from m...
  • Loading branch information
hollie committed Mar 2, 2015
2 parents 2470b2e + 67db903 commit 06ef5c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/AnalogSensor_Item.pm
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ sub map_to_weather {
my $rrd_ref = &AnalogSensor_Item::weather_to_rrd(lc $p_hash_ref);
my $sensor_names = $main::config_parms{weather_graph_sensor_names};
if ($sensor_names) {
if ($sensor_names !~ /$rrd_ref/i) {
if ($sensor_names !~ /$rrd_ref\W/i) {
$sensor_names .= ", $rrd_ref => $p_sensor_name";
$main::config_parms{weather_graph_sensor_names} = $sensor_names;
print "[AnalogSensor] weather_graph_sensor_names: $sensor_names\n" if $main::Debug{analogsensor};
Expand Down

0 comments on commit 06ef5c8

Please sign in to comment.