Skip to content

Commit

Permalink
Fix test after rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
Vincent Prouillet committed Nov 25, 2018
1 parent 80853d5 commit e0633e4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/builtins/filters/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ mod tests {

#[test]
fn test_filter_empty() {
let res = filter(json!([]), HashMap::new());
let res = filter(&json!([]), &HashMap::new());
assert!(res.is_ok());
assert_eq!(res.unwrap(), json!([]));
}
Expand Down
2 changes: 1 addition & 1 deletion src/builtins/filters/object.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use errors::{Error, Result};
pub fn get(value: &Value, args: &HashMap<String, Value>) -> Result<Value> {
let key = match args.get("key") {
Some(val) => try_get_value!("get", "key", String, val),
None => bail!("The `get` filter has to have an `key` argument"),
None => { return Err(Error::msg("The `get` filter has to have an `key` argument")) },
};

match value.as_object() {
Expand Down

0 comments on commit e0633e4

Please sign in to comment.