added log_to_sender functionality