mirror of
https://github.com/kristoferssolo/tg-relay-rs.git
synced 2025-12-20 11:04:41 +00:00
parent
4260bb5271
commit
6a50806fa5
@ -13,7 +13,7 @@ static SHORTCODE_RE: OnceLock<Regex> = OnceLock::new();
|
||||
|
||||
fn shortcode_regex() -> &'static Regex {
|
||||
SHORTCODE_RE.get_or_init(|| {
|
||||
Regex::new(r"https?://(?:www\.)?(?:youtube\.com/shorts/[A-Za-z0-9_-]+(?:\?[^\s]*)?")
|
||||
Regex::new(r"https?:\/\/(?:www\.)?youtube\.com\/shorts\/[A-Za-z0-9_-]+(?:\?[^\s]*)?")
|
||||
.expect("filed to compile regex")
|
||||
})
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user