Merge a5ebce7f2e24e7bfec45066f7e11fb60f16ab9af into 396c6c8e93928e1f6b4f498c0affae2c55fb6110

This commit is contained in:
Bart van Andel 2026-08-06 08:45:37 +02:00 committed by GitHub
commit cbdcb56318
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -242,6 +242,10 @@ class Operation {
* @param {Object[]} ingValues * @param {Object[]} ingValues
*/ */
set ingValues(ingValues) { set ingValues(ingValues) {
if (ingValues.length > this._ingList.length) {
throw new OperationError(`Failed to set ingredient values: more values provided than available ingredients (${ingValues.length} vs ${this._ingList.length})`);
}
ingValues.forEach((val, i) => { ingValues.forEach((val, i) => {
try { try {
this._ingList[i].value = val; this._ingList[i].value = val;