mirror of
https://github.com/fluencelabs/jsonpath
synced 2025-06-18 02:21:30 +00:00
Remove Parser's lifetime
This commit is contained in:
@ -508,8 +508,7 @@ impl<'a> Selector<'a> {
|
||||
|
||||
pub fn path(&mut self, path: &str) -> Result<&mut Self, JsonPathError> {
|
||||
debug!("path : {}", path);
|
||||
let mut parser = Parser::new(path);
|
||||
self.node = Some(parser.compile().map_err(|e| JsonPathError::Path(e))?);
|
||||
self.node = Some(Parser::compile(path).map_err(|e| JsonPathError::Path(e))?);
|
||||
Ok(self)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user