iot_message/message.py
def _validate_message(self, message):
        """:return boolean"""
        if 'protocol' not in message or 'targets' not in message or \
                type(message['targets']) is not list:
            return False

        if message['protocol'] != self.protocol:
            return False

        if self.node not in message['targets'] and 'ALL' not in message['targets']:
            return False

        return True
def _validate_message(self, message):
        """:return boolean"""
        if 'protocol' not in message or 'targets' not in message or \
                type(message['targets']) is not list:
            return False

        if message['protocol'] != self.protocol:
            return False

        if self.node not in message['targets'] and 'ALL' not in message['targets']:
            return False

        return True
:return boolean