Skip to content

Commit 342acc8

Browse files
committed
🐛 [#539] Handle resultaat on zaak
1 parent bc2e54d commit 342acc8

File tree

1 file changed

+2
-1
lines changed
  • backend/src/openarchiefbeheer/zaken

1 file changed

+2
-1
lines changed

backend/src/openarchiefbeheer/zaken/utils.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -127,14 +127,15 @@ def format_selectielijstklasse_choice(resultaat: Resultaat) -> DropDownChoice:
127127
}
128128

129129

130-
def format_resultaten_choices(resultaten: list[dict]) -> DropDownChoice:
130+
def format_resultaten_choices(resultaten: list[dict | None]) -> DropDownChoice:
131131
result = [
132132
{
133133
"value": resultaat["_expand"]["resultaattype"]["url"],
134134
"label": resultaat["_expand"]["resultaattype"]["omschrijving"],
135135
"extra_data": {"toelichting": resultaat.get("toelichting")},
136136
}
137137
for resultaat in resultaten
138+
if resultaat
138139
]
139140
return result
140141

0 commit comments

Comments
 (0)