add comment on limiting the other rate

This commit is contained in:
Tor Harald Sandve 2024-11-06 11:06:35 +01:00
parent e372bde838
commit 38be1ac83f

View File

@ -666,10 +666,11 @@ getRateWithLimit_(Rate rate_type, const BasicRates& rates) const
// for why the rate was limited.
std::optional<Rate> target_type;
Scalar rate2;
// we also need to limit the other rate (currently only for water and oil and not gas)
Scalar rate2 = 0.0;
if (rate_type == Rate::oil) {
rate2 = getRate_(Rate::water, rates);
} else {
} else if (rate_type == Rate::water) {
rate2 = getRate_(Rate::oil, rates);
}