Update lib.rs

This commit is contained in:
Guy Korland 2019-07-31 16:34:24 +03:00 committed by GitHub
parent d9b9e9d8bd
commit 2efb019155
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -299,7 +299,7 @@ pub fn selector_as<T: serde::de::DeserializeOwned>(
/// &json!({"name": "친구1", "age": 20})
/// ]);
/// ```
pub fn select<'a>(json: &'a Value, path: &'a str) -> Result<Vec<&'a Value>, JsonPathError> {
pub fn select<'a>(json: &'a Value, path: &str) -> Result<Vec<&'a Value>, JsonPathError> {
Selector::default().str_path(path)?.value(json).select()
}