trees: fix pfaf getting
This commit is contained in:
parent
0364650831
commit
a29d2e6be0
|
@ -87,7 +87,9 @@ pub fn get_tree(state: State) -> (State, Response<Body>) {
|
|||
let point: Point<f64> = row.get(1);
|
||||
let mut details: HashMap<String, String> = HashMap::with_capacity(PFAF_COLS.len());
|
||||
for (i, col) in PFAF_COLS.iter().enumerate() {
|
||||
details.insert(col.to_string(), pfaf_row.get(i));
|
||||
if let Some(value) = pfaf_row.get(i) {
|
||||
details.insert(col.to_string(), value);
|
||||
}
|
||||
}
|
||||
Tree {
|
||||
id: row.get(0),
|
||||
|
|
Loading…
Reference in New Issue