Updated MessageDAO save function