Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ZENOTME committed Jan 22, 2024
1 parent bc926bd commit 0cc5ba9
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/frontend/src/handler/create_sink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -306,11 +306,9 @@ pub async fn get_partition_compute_info(
with_options: &WithOptions,
) -> Result<Option<PartitionComputeInfo>> {
let properties = HashMap::from_iter(with_options.clone().into_inner().into_iter());
let connector = properties.get(UPSTREAM_SOURCE_KEY).ok_or_else(|| {
RwError::from(ErrorCode::SinkError(
format!("missing field {UPSTREAM_SOURCE_KEY} in sink config").into(),
))
})?;
let Some(connector) = properties.get(UPSTREAM_SOURCE_KEY) else {
return Ok(None);
};
match connector.as_str() {
ICEBERG_SINK => {
let iceberg_config = IcebergConfig::from_hashmap(properties)?;
Expand Down

0 comments on commit 0cc5ba9

Please sign in to comment.