mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-29 19:10:42 +01:00
HydraulicStructures: fix crash when selecting a rk before the reach
This commit is contained in:
1 parent
cdeca8a2e8
commit
d8d1b4cd1f
1 file changed
+2
-1
@@ -96,7 +96,8 @@ class ComboBoxDelegate(QItemDelegate):
|
||||
reach = self._data.hydraulic_structures\
|
||||
.get(index.row())\
|
||||
.input_reach
|
||||
profiles = list(
|
||||
# No reach selected yet: no profile to choose from
|
||||
profiles = [] if reach is None else list(
|
||||
filter(
|
||||
lambda p: p.display_name() == text,
|
||||
reach.reach.profiles
|
||||
|
||||
Reference in new issue
Block a user