Skip to content

Commit

Permalink
Fix description regex to accept _, -, space
Browse files Browse the repository at this point in the history
  • Loading branch information
vladvasiliu committed Apr 25, 2022
1 parent 670552e commit 8803312
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "aws_doorman"
version = "0.4.1"
version = "0.4.2"
authors = ["Vlad Vasiliu"]
edition = "2021"

Expand Down
2 changes: 1 addition & 1 deletion src/config/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ fn check_prefix_list_format(pl: &str) -> Result<(), String> {

fn check_description(desc: &str) -> Result<(), String> {
lazy_static! {
static ref RE: Regex = Regex::new(r"\A(?i:[[:alnum:]]{0, 255})\z").unwrap();
static ref RE: Regex = Regex::new(r"\A(?i:([[:alnum:]]|[ -_]){0, 255})\z").unwrap();
}
match RE.is_match(desc) {
true => Ok(()),
Expand Down

0 comments on commit 8803312

Please sign in to comment.