Append message ID to error.messageIds for sendMessage