Skip to content
Permalink
Browse files

Bugfix: Skip transformations that don't have values

  • Loading branch information...
timeu committed Sep 5, 2019
1 parent 223ee75 commit 0b6ab72d950cb4652e2cf4f185506e5520412493
Showing with 2 additions and 1 deletion.
  1. +2 −1 arapheno/phenotypedb/renderer.py
@@ -35,7 +35,8 @@ def render(self, data, media_type=None, renderer_context={}, writer_opts=None):
for ix, accession in enumerate(data['accessions']):
row = {'accession_id': data['accessions'][ix][0]}
for transformation, info in data['transformations'].items():
row[transformation] = info['values'][ix][1]
if len(info['values']) > 0:
row[transformation] = info['values'][ix][1]
converted_data.append(row)
return super(TransformationRenderer, self).render(converted_data, media_type, renderer_context,writer_opts)

0 comments on commit 0b6ab72

Please sign in to comment.
You can’t perform that action at this time.