mirror of
https://github.com/kristoferssolo/tg-relay-rs.git
synced 2025-12-20 11:04:41 +00:00
fix(youtube): remove non-shorts regex
This commit is contained in:
parent
a83dff719f
commit
2d4a409b84
@ -13,9 +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]*)?|youtu\.be/[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