File tree Expand file tree Collapse file tree 1 file changed +13
-10
lines changed
raphtory-api/src/core/entities/properties/prop Expand file tree Collapse file tree 1 file changed +13
-10
lines changed Original file line number Diff line number Diff line change @@ -168,16 +168,19 @@ impl<'a> ArrowRow<'a> {
168168 }
169169
170170 pub fn into_prop ( self ) -> Option < Prop > {
171- let map = Prop :: map (
172- self . array
173- . fields ( )
174- . iter ( )
175- . enumerate ( )
176- . filter_map ( |( col, field) | Some ( ( field. name ( ) . as_ref ( ) , self . prop_value ( col) ?) ) ) ,
177- ) ;
178- match map {
179- Prop :: Map ( m) if m. is_empty ( ) => None ,
180- _ => Some ( map) ,
171+ if self . index >= self . array . len ( ) || self . array . is_null ( self . index ) {
172+ None
173+ } else {
174+ let map = Prop :: map (
175+ self . array
176+ . fields ( )
177+ . iter ( )
178+ . enumerate ( )
179+ . filter_map ( |( col, field) | {
180+ Some ( ( field. name ( ) . as_ref ( ) , self . prop_value ( col) ?) )
181+ } ) ,
182+ ) ;
183+ Some ( map)
181184 }
182185 }
183186
You can’t perform that action at this time.
0 commit comments