Merge pull request #88 from meguminloli/re_username

This commit is contained in:
Paul Makles
2021-09-15 21:30:58 +01:00
committed by GitHub
6 changed files with 9 additions and 27 deletions

View File

@@ -1,3 +1,4 @@
pub mod result;
pub mod variables;
pub mod ratelimit;
pub mod regex;

4
src/util/regex.rs Normal file
View File

@@ -0,0 +1,4 @@
use once_cell::sync::Lazy;
use regex::Regex;
pub static RE_USERNAME: Lazy<Regex> = Lazy::new(|| Regex::new(r"^[a-zA-Z0-9_.]+$").unwrap());