Mon, 02 May 2022 21:09:48 +0200
Fix fermentable percent check if there are no fermentables.
src/EditProduct.cpp | file | annotate | diff | comparison | revisions |
--- a/src/EditProduct.cpp Mon May 02 16:40:41 2022 +0200 +++ b/src/EditProduct.cpp Mon May 02 21:09:48 2022 +0200 @@ -401,7 +401,7 @@ product->fermentables.append(f); } qDebug() << "fermentables" << product->fermentables.size() << percentcheck; - if (percentcheck == 0) { + if (percentcheck == 0 && product->fermentables.size()) { /* Missing percentages, fix it. */ double total = 0; for (int i = 0; i < product->fermentables.size(); i++) {