diff --git a/README.md b/README.md index 42f7383e..63a4012c 100644 --- a/README.md +++ b/README.md @@ -251,13 +251,13 @@ Tests whether the string matches the regex given. `regex` takes Examples: ```rust -use once_cell::sync::Lazy; +use std::sync::LazyLock; static RE_TWO_CHARS: Lazy = Lazy::new(|| { Regex::new(r"[a-z]{2}$").unwrap() }); -#[validate(regex(path = *RE_TWO_CHARS)] +#[validate(regex(path = *RE_TWO_CHARS))] ``` ### credit\_card