@slot-engine/core 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -2516,10 +2516,10 @@ var Optimizer = class {
2516
2516
  const conditions = Object.keys(mode.conditions);
2517
2517
  const scalings = Object.keys(mode.scaling);
2518
2518
  const parameters = Object.keys(mode.parameters);
2519
- for (const condition of conditions) {
2520
- if (!configMode.resultSets.find((r) => r.criteria === condition)) {
2519
+ for (const rs of configMode.resultSets) {
2520
+ if (!conditions.includes(rs.criteria)) {
2521
2521
  throw new Error(
2522
- `Condition "${condition}" defined in optimizer config for game mode "${k}" does not exist as criteria in any ResultSet of the same game mode.`
2522
+ `ResultSet criteria "${rs.criteria}" in game mode "${k}" does not have a corresponding optimization condition defined.`
2523
2523
  );
2524
2524
  }
2525
2525
  }