diff options
| author | a14m <[email protected]> | 2021-04-06 00:28:29 +0200 |
|---|---|---|
| committer | a14m <[email protected]> | 2021-04-06 00:28:29 +0200 |
| commit | 0a51021e8943432211736c2307e7434d6afc5904 (patch) | |
| tree | ba8e36b42df0fd0c3870fb96303d0169d0340ce3 /CLI | |
| parent | aedde6637c30c9c2dc22b1978bd5a692d5ff5def (diff) | |
Fix the regex to test URLs
Diffstat (limited to 'CLI')
| -rw-r--r-- | CLI/rust/src/game_of_life/generators/input.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/CLI/rust/src/game_of_life/generators/input.rs b/CLI/rust/src/game_of_life/generators/input.rs index 235b3b2..dc22525 100644 --- a/CLI/rust/src/game_of_life/generators/input.rs +++ b/CLI/rust/src/game_of_life/generators/input.rs @@ -15,7 +15,7 @@ use mocktopus::macros::mockable; #[cfg_attr(test, mockable)] pub(crate) fn new(opts: Opts) -> Result<Universe, Error> { let input = opts.input.clone().unwrap(); - match Regex::new("^(ht|f)?tp(s)?://*").unwrap().is_match(&input) { + match Regex::new("^(ht|f)tp(s)?://*").unwrap().is_match(&input) { true => generate_url_data(opts), false => generate_file_data(opts), } |
