#14434 Guard against missing perforation interval in templateUpdated

This commit is contained in:
Magne Sjaastad committed 2026-07-31 16:38:33 +02:00
1 parent af2c5d429c
commit 134befead4
3 files changed
+45 -2

No files matched your search

@@ -549,8 +549,11 @@ void RimWellPathValve::templateUpdated()
{
applyValveLabelAndIcon();
auto perforationInterval = firstAncestorOrThisOfType<RimPerforationInterval>();
perforationInterval->updateAllReferringTracks();
// A valve can also be a stand-alone valve or a tie-in outlet valve, and then has no perforation interval
if ( auto perforationInterval = firstAncestorOrThisOfType<RimPerforationInterval>() )
{
perforationInterval->updateAllReferringTracks();
}
RimProject* proj = RimProject::current();
proj->reloadCompletionTypeResultsInAllViews();