fixes sendMessage crash (maybe???)