Skip to content

Commit

Permalink
Simplified a bit more
Browse files Browse the repository at this point in the history
  • Loading branch information
vgapeyev committed May 18, 2024
1 parent e83593f commit 51f252c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions datafusion/functions/src/core/getfield.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,17 @@ impl ScalarUDFImpl for GetFieldFunc {
.iter()
.find_map(|field| {
if field.name() == "values" {
Some((field.data_type(), field.is_nullable()))
Some(field.data_type())
} else {
None
}
})
.expect("map type without value is not supported");
return Ok(value_dt.0.clone());
return Ok(value_dt.clone());
}
return exec_err!("Malformed DataType::Map -- does not wrap over a DataType::Struct, got {}", &args[0]);
}
todo!("get_field function is not implemented for this type");
todo!("get_field function is not implemented for this type: {}", &args[0]);
}

fn return_type_from_exprs(
Expand Down

0 comments on commit 51f252c

Please sign in to comment.