diff --git a/pywr-schema/src/model.rs b/pywr-schema/src/model.rs index 84fa6b0c..c2a17556 100644 --- a/pywr-schema/src/model.rs +++ b/pywr-schema/src/model.rs @@ -879,7 +879,7 @@ impl PywrMultiNetworkModel { let mut model = pywr_core::models::MultiNetworkModel::new(domain); for (name, network) in networks { - model.add_network(&name, network); + model.add_network(&name, network)?; } for (from_network_idx, from_metric, to_network_idx, initial_value) in inter_network_transfers {