Skip to content

Commit 6ad4848

Browse files
committed
Address comments
Signed-off-by: Santiago Figueroa Manrique <santiago.figueroa.manrique@alliander.com>
1 parent c129a50 commit 6ad4848

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

power_grid_model_c/power_grid_model/include/power_grid_model/main_core/update.hpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,8 +227,7 @@ get_all_sequence_idx_map(MainModelState<ComponentContainer> const& state, ConstD
227227
// The sequence for the independent components is cached (true). For the remaining components, the sequence
228228
// cannot be cached (false), so the independence flags are inverted to not return an empty sequence when
229229
// this is the case.
230-
bool const component_independence =
231-
!cached ? component_properties.is_independent() : !component_properties.is_independent();
230+
bool const component_independence = cached != component_properties.is_independent();
232231
if (!component_independence ||
233232
!std::get<utils::index_of_component<CompType, ComponentTypes...>>(components_to_store)) {
234233
return std::vector<Idx2D>{};

power_grid_model_c/power_grid_model/include/power_grid_model/main_model_impl.hpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,6 @@ class MainModelImpl<ExtraRetrievableTypes<ExtraRetrievableType...>, ComponentLis
292292
}
293293
// overload to update all components in the first scenario (e.g. permanent update)
294294
template <cache_type_c CacheType> void update_components(ConstDataset const& update_data) {
295-
296295
auto const components_to_update = get_components_to_update(update_data);
297296
auto const update_independence =
298297
main_core::update::independence::check_update_independence<ComponentType...>(state_, update_data);

0 commit comments

Comments
 (0)