Skip to content

Commit ed6b0eb

Browse files
committed
more syntax fix
1 parent ac4bde3 commit ed6b0eb

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

crates/iceberg/src/writer/file_writer/rolling_writer.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -112,15 +112,13 @@ impl<B: FileWriterBuilder> FileWriter for RollingFileWriter<B> {
112112

113113
// write the input
114114
if let Some(writer) = self.inner.as_mut() {
115-
writer.write(input).await?;
115+
Ok(writer.write(input).await?)
116116
} else {
117-
return Err(Error::new(
117+
Err(Error::new(
118118
ErrorKind::Unexpected,
119119
"Writer is not initialized!",
120-
));
121-
};
122-
123-
Ok(())
120+
))
121+
}
124122
}
125123

126124
async fn close(mut self) -> Result<Vec<DataFileBuilder>> {

0 commit comments

Comments
 (0)