Skip to content

Commit

Permalink
Fix instance where current case was None
Browse files Browse the repository at this point in the history
  • Loading branch information
oyvindeide committed Sep 6, 2023
1 parent 2731d1e commit 824f6ea
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/ert/gui/ertnotifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ def config_file(self) -> str:

@property
def current_case(self) -> Optional[EnsembleReader]:
if self._current_case is None and self._storage is not None:
ensembles = list(self._storage.ensembles)
if ensembles:
self._current_case = ensembles[0]
return self._current_case

@property
Expand Down

0 comments on commit 824f6ea

Please sign in to comment.