From 0dafce88a323c9da01113fe72feec147c98edf8a Mon Sep 17 00:00:00 2001 From: Bill Richardson Date: Thu, 23 Jul 2026 11:23:33 -0400 Subject: [PATCH] bailout addded to navigatewithsingle and a copilot suggestion --- src/helpers/vehicle-helper.js | 5 +++-- src/mixins/vin-pages-mixin.js | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/helpers/vehicle-helper.js b/src/helpers/vehicle-helper.js index 4d0bef51..7902b3fa 100644 --- a/src/helpers/vehicle-helper.js +++ b/src/helpers/vehicle-helper.js @@ -11,8 +11,9 @@ export function hasYMMExperimentPageSettingEnabled() { } export function hasYMMExperimentSettingEnabled() { - return experimentMixin.methods.hasSettingEqualTo(experimentSettings.ISS_YMMS_VIN_REQUIRED_PAGE_ENABLED, 'true') - || experimentMixin.methods.hasSettingEqualTo(experimentSettings.ISS_YMMS_VIN_REQUIRED_BAILOUT_ENABLED, 'true'); + return ymmIsVinRequired() + && (experimentMixin.methods.hasSettingEqualTo(experimentSettings.ISS_YMMS_VIN_REQUIRED_PAGE_ENABLED, 'true') + || experimentMixin.methods.hasSettingEqualTo(experimentSettings.ISS_YMMS_VIN_REQUIRED_BAILOUT_ENABLED, 'true')); } function ymmIsVinRequired() { diff --git a/src/mixins/vin-pages-mixin.js b/src/mixins/vin-pages-mixin.js index c189471b..9c943c93 100644 --- a/src/mixins/vin-pages-mixin.js +++ b/src/mixins/vin-pages-mixin.js @@ -9,6 +9,10 @@ export default { let result; if (this.mainStore.order.vehicle.vinRequired) { result = await useMainStore().getPartsOrQuestionsV2(); + if (result.data.partsOrQuestions.length === 0) { + this.navigateBailout(bailoutMessage.YMMNotFound('No Parts Returned')); + return; + } } else { result = await useMainStore().getPartsOrQuestions(); }