add safety check to message delete