fix deletion of messages