File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed
connectorx/src/destinations/arrow2 Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -448,13 +448,19 @@ impl ArrowAssoc for Option<Vec<String>> {
448
448
}
449
449
450
450
fn push ( builder : & mut Self :: Builder , value : Self ) {
451
- let value = value. unwrap ( ) ;
452
451
let mut string_array: Vec < Option < String > > = vec ! [ ] ;
453
- for sub_value in value {
454
- string_array. push ( Some ( sub_value) )
455
- }
452
+ match value {
453
+ Some ( value) => {
454
+ for sub_value in value {
455
+ string_array. push ( Some ( sub_value) )
456
+ }
456
457
457
- builder. try_push ( Some ( string_array) ) ;
458
+ builder. try_push ( Some ( string_array) ) . unwrap ( ) ;
459
+ }
460
+ None => {
461
+ builder. try_push ( Some ( string_array) ) . unwrap ( ) ;
462
+ }
463
+ } ;
458
464
}
459
465
460
466
fn field ( header : & str ) -> Field {
@@ -474,7 +480,7 @@ impl ArrowAssoc for Vec<String> {
474
480
for sub_value in value {
475
481
string_array. push ( Some ( sub_value) )
476
482
}
477
- builder. try_push ( Some ( string_array) ) ;
483
+ builder. try_push ( Some ( string_array) ) . unwrap ( ) ;
478
484
}
479
485
480
486
fn field ( header : & str ) -> Field {
You can’t perform that action at this time.
0 commit comments