From c717c8d7a1ad2b9fb517dc68453f21deb333c3aa Mon Sep 17 00:00:00 2001 From: LeoniePhiline <22329650+LeoniePhiline@users.noreply.github.com> Date: Sat, 21 Jan 2023 12:34:26 +0100 Subject: [PATCH] fix: Regex failed to match valid embeds --- src/main.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.rs b/src/main.rs index 19ba38d..73ed26e 100644 --- a/src/main.rs +++ b/src/main.rs @@ -72,7 +72,7 @@ async fn extract_and_download(state: Arc, url: &str) -> Result<()> { async fn process_simple_embeds(page_body: &str, referer: &str, state: Arc) -> Result<()> { lazy_static! { static ref RE: Regex = Regex::new( - r#"]+ src="(?Phttps://player\.vimeo\.com/video/[^"]+)""# + r#"]* src="(?Phttps://player\.vimeo\.com/video/[^"]+)""# ) .unwrap(); } @@ -160,7 +160,7 @@ async fn extract_simple_embed_title(video: Arc