'Add `item` to queue.
Except `item` is an instance of
:class:`coalib.processes.communication.LogMessage.LogMessage` and
there is a ``self.log_printer``. Then `item` is just sent to logger
instead.'

def put(self, item):

    if ((self.log_printer is not None) and isinstance(item, LogMessage)):
        self.log_printer.log_message(item)
    else:
        super().put(item)
