From f5ef0f0fcef8989716cb23338423356c87c1d246 Mon Sep 17 00:00:00 2001 From: Rob Ede Date: Fri, 27 Sep 2024 17:10:33 +0100 Subject: [PATCH] docs(webpki-roots): simplify usage example --- webpki-roots/src/lib.rs | 2 +- webpki-roots/tests/codegen.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/webpki-roots/src/lib.rs b/webpki-roots/src/lib.rs index c97571b..989e780 100644 --- a/webpki-roots/src/lib.rs +++ b/webpki-roots/src/lib.rs @@ -4,7 +4,7 @@ //! //! ```rust //! let root_store = rustls::RootCertStore { -//! roots: webpki_roots::TLS_SERVER_ROOTS.iter().cloned().collect(), +//! roots: webpki_roots::TLS_SERVER_ROOTS.to_vec(), //! }; //! ``` //! diff --git a/webpki-roots/tests/codegen.rs b/webpki-roots/tests/codegen.rs index 70fff28..4258354 100644 --- a/webpki-roots/tests/codegen.rs +++ b/webpki-roots/tests/codegen.rs @@ -141,7 +141,7 @@ const HEADER: &str = r#"//! A compiled-in copy of the root certificates trusted //! //! ```rust //! let root_store = rustls::RootCertStore { -//! roots: webpki_roots::TLS_SERVER_ROOTS.iter().cloned().collect(), +//! roots: webpki_roots::TLS_SERVER_ROOTS.to_vec(), //! }; //! ``` //!