Skip to content

Commit 1cb8ae2

Browse files
authored
Merge pull request #505 from citrus-it/list
Traceback when listing packages with empty fields
2 parents ef49a59 + ba91792 commit 1cb8ae2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/client.py

+2
Original file line numberDiff line numberDiff line change
@@ -682,6 +682,8 @@ def calc_fmtstr(attrs, data):
682682

683683
for entry in data:
684684
for i, field in enumerate(attrs):
685+
if not entry.get(field):
686+
continue
685687
if len(entry.get(field)) > widths[i]:
686688
widths[i] = len(entry.get(field))
687689

0 commit comments

Comments
 (0)