Merge pull request #1072 from Safelite/feature/CSR-1338

CSR-1338
This commit is contained in:
CarlNation 2023-04-21 13:47:55 -04:00 committed by GitHub
commit b26acd3c06
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View file

@ -46,7 +46,7 @@ export function getIsWindshieldOnly() {
return returnString;
}
export function hasWindshield() {
export function includesWindshieldReplacement() {
const windshieldMatches =
store.getters.order.damage.glassToReplace?.filter(
(glassToReplace) => glassToReplace.glassLocation === glassLocations.WINDSHIELD

View file

@ -7,7 +7,7 @@ import { storeActions } from "@/constants/store-actions.js";
import { settleAllPromises } from "@/helpers/layout-helper";
import experimentMixin from "@/mixins/experiment-mixin";
import { experimentSettings } from "@/constants/experiments";
import { hasWindshield } from "@/helpers/damage-helper";
import { includesWindshieldReplacement } from "@/helpers/damage-helper";
import store from "@/store";
import router from "@/router";
@ -74,7 +74,7 @@ export async function skipVinLookup() {
return (
store.getters.damage.isRepair ||
isVinOptionalVehicle ||
!hasWindshield() ||
!includesWindshieldReplacement() ||
experimentMixin.methods.hasSettingEqualTo(experimentSettings.SUPPRESS_VIN_CAPTURE, "true")
);
}
@ -87,7 +87,7 @@ export async function skipVinLookupNotRepair() {
return (
!store.getters.damage.isRepair &&
(isVinOptionalVehicle ||
!hasWindshield() ||
!includesWindshieldReplacement() ||
experimentMixin.methods.hasSettingEqualTo(
experimentSettings.SUPPRESS_VIN_CAPTURE,
"true"