Skip to content

Commit

Permalink
BigQuey fix invalid null checks in io translation (apache#32515)
Browse files Browse the repository at this point in the history
  • Loading branch information
RustedBones authored and reeba212 committed Dec 4, 2024
1 parent 9e4efae commit be77afe
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ public TypedRead<?> fromConfigRow(Row configRow, PipelineOptions options) {
builder = builder.setMethod((TypedRead.Method) fromByteArray(methodBytes));
}
byte[] formatBytes = configRow.getBytes("format");
if (methodBytes != null) {
if (formatBytes != null) {
builder = builder.setFormat((DataFormat) fromByteArray(formatBytes));
}
Collection<String> selectedFields = configRow.getArray("selected_fields");
Expand Down Expand Up @@ -641,7 +641,7 @@ public Write<?> fromConfigRow(Row configRow, PipelineOptions options) {
}
byte[] formatRecordOnFailureFunctionBytes =
configRow.getBytes("format_record_on_failure_function");
if (tableFunctionBytes != null) {
if (formatRecordOnFailureFunctionBytes != null) {
builder =
builder.setFormatRecordOnFailureFunction(
(SerializableFunction<?, TableRow>)
Expand All @@ -654,7 +654,7 @@ public Write<?> fromConfigRow(Row configRow, PipelineOptions options) {
(AvroRowWriterFactory) fromByteArray(avroRowWriterFactoryBytes));
}
byte[] avroSchemaFactoryBytes = configRow.getBytes("avro_schema_factory");
if (tableFunctionBytes != null) {
if (avroSchemaFactoryBytes != null) {
builder =
builder.setAvroSchemaFactory(
(SerializableFunction) fromByteArray(avroSchemaFactoryBytes));
Expand Down

0 comments on commit be77afe

Please sign in to comment.