Ignore:
Timestamp:
01/26/13 10:07:50 (11 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
default
Phase:
public
Message:

The lights whose value cannot be detected are not logged (re #180)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/checks.py

    r415 r416  
    599599    def _getMessage(self, flight, state, forced):
    600600        """Get the message from the given state."""
    601         return self._template % ("ON" if self._getValue(state) else "OFF")
     601        value = self._getValue(state)
     602        if value is None:
     603            return None
     604        else:
     605            return self._template % ("ON" if value else "OFF")
    602606
    603607#---------------------------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.