Added edit and delete message functionality