adds logging for send_message