sendMessage bugfixes