Make sure one case is loaded when both SMSPEC and ESMRY is present in same folder

This commit is contained in:
Magne Sjaastad 2023-05-30 14:09:00 +02:00
parent 24ccbf395d
commit fc51bf84a5

View File

@ -70,6 +70,12 @@ std::vector<QString> RiaEclipseFileNameTools::findSummaryFileCandidates()
auto smryCandidate = relatedFilePath( EclipseFileType::ECLIPSE_SMSPEC );
auto esmryCandidate = relatedFilePath( EclipseFileType::ECLIPSE_ESMRY );
if ( !smryCandidate.isEmpty() && !esmryCandidate.isEmpty() )
{
// If both files exist, we prefer the SMSPEC file
esmryCandidate = "";
}
return { smryCandidate, esmryCandidate };
}