we arent going to download from ftp lol
This commit is contained in:
parent
1fef3288ca
commit
6599410768
1 changed files with 1 additions and 1 deletions
|
|
@ -3,7 +3,7 @@ use url::Url;
|
|||
|
||||
// https://stackoverflow.com/questions/6038061/regular-expression-to-find-urls-within-a-string
|
||||
const RE_URL: &str =
|
||||
r"(http|ftp|https):\/\/([\w_-]+(?:(?:\.[\w_-]+)+))([\w.,@?^=%&:\/~+#-]*[\w@?^=%&\/~+#-])";
|
||||
r"(http|https):\/\/([\w_-]+(?:(?:\.[\w_-]+)+))([\w.,@?^=%&:\/~+#-]*[\w@?^=%&\/~+#-])";
|
||||
|
||||
pub fn extract_url(text: &str) -> Option<&str> {
|
||||
let re = Regex::new(RE_URL).unwrap();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue