Skip to content

Commit

Permalink
fix in query argument parser
Browse files Browse the repository at this point in the history
  • Loading branch information
proycon committed May 27, 2024
1 parent 6a8c7bf commit 1434ee2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "stam"
version = "0.14.0"
version = "0.14.1"
edition = "2021"
authors = ["Maarten van Gompel <[email protected]>"]
description = "STAM is a powerful library for dealing with stand-off annotations on text"
Expand Down
4 changes: 2 additions & 2 deletions src/api/query.rs
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,7 @@ impl<'a> Constraint<'a> {
StamError::QuerySyntaxError(
format!(
"expected integer as 2nd parameter after LIMIT, got '{}'",
arg
end
),
"Parsing LIMIT constraint failed",
)
Expand Down Expand Up @@ -3439,7 +3439,7 @@ fn get_arg<'a>(querystring: &'a str) -> Result<(&'a str, &'a str, ArgType), Stam
return Ok((arg, &querystring[i + 1..].trim_start(), get_arg_type(arg)));
} else if !quote && (c == ';' || c == ' ' || c == ']' || c == '\n' || c == '\t') {
let arg = &querystring[0..i];
return Ok((arg, &querystring[i + 1..].trim_start(), get_arg_type(arg)));
return Ok((arg, &querystring[i..].trim_start(), get_arg_type(arg)));
}
escaped = c == '\\';
}
Expand Down

0 comments on commit 1434ee2

Please sign in to comment.