diff --git a/src/libs/antares/study/area/list.cpp b/src/libs/antares/study/area/list.cpp index 3cf742ca74..6aca1bbd58 100644 --- a/src/libs/antares/study/area/list.cpp +++ b/src/libs/antares/study/area/list.cpp @@ -1217,12 +1217,7 @@ bool AreaList::loadFromFolder(const StudyLoadOptions& options) // in order to allocate data with all renewable clusters. fs::path renewClusterPath = pStudy.folderInput / "renewables" / "clusters"; - if (!fs::is_directory(renewClusterPath)) - { - logs.info() << "Renewable directory missing " << renewClusterPath; - logs.info() << "Skipped loading renewable clusters"; - } - else + if (fs::is_directory(renewClusterPath)) { auto end = areas.end(); for (auto i = areas.begin(); i != end; ++i) @@ -1233,6 +1228,11 @@ bool AreaList::loadFromFolder(const StudyLoadOptions& options) ret = area.renewable.list.validateClusters() && ret; } } + else + { + logs.info() << "Renewable directory missing " << renewClusterPath; + logs.info() << "Skipped loading renewable clusters"; + } } // Prepare