hevy-shared 1.0.717 → 1.0.718

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.
@@ -206,6 +206,12 @@ const pickExerciseForPrescription = (params) => {
206
206
  return exercise;
207
207
  // Pass 4: Find alternative isolation exercise not used in routine
208
208
  exercise = findAlternativeIsolationExercise(exercises, criteria, routineContext);
209
+ if (exercise)
210
+ return exercise;
211
+ // Pass 5: Find compound exercise that uses the same muscle group as the isolation exercise
212
+ if (criteria.exerciseCategory === 'isolation') {
213
+ exercise = findMatchingExercise(exercises, Object.assign(Object.assign({}, criteria), { exerciseCategory: 'compound' }), routineContext);
214
+ }
209
215
  return exercise;
210
216
  };
211
217
  exports.pickExerciseForPrescription = pickExerciseForPrescription;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hevy-shared",
3
- "version": "1.0.717",
3
+ "version": "1.0.718",
4
4
  "description": "",
5
5
  "main": "built/index.js",
6
6
  "types": "built/index.d.ts",