fix: use .some() instead of .filter() in isRecalPartOrHasChildRecalPart to return boolean
Agent-Logs-Url: https://github.com/Safelite/DigitalConsumer.ISS/sessions/af7c0e65-2f59-45e0-8c49-f5c468cafa1a Co-authored-by: katiekroell <100247286+katiekroell@users.noreply.github.com>
This commit is contained in:
parent
744f1b4724
commit
94f1504ef9
1 changed files with 1 additions and 1 deletions
|
|
@ -11,7 +11,7 @@ export function isRecalPartOrHasChildRecalPart(glassPart) {
|
||||||
const isGlassPartRecalPart = isRecalPart(glassPart);
|
const isGlassPartRecalPart = isRecalPart(glassPart);
|
||||||
|
|
||||||
if (!isGlassPartRecalPart && glassPart.childParts && glassPart.childParts.length > 0) {
|
if (!isGlassPartRecalPart && glassPart.childParts && glassPart.childParts.length > 0) {
|
||||||
return glassPart.childParts.filter((cp) => isRecalPartOrHasChildRecalPart(cp));
|
return glassPart.childParts.some((cp) => isRecalPartOrHasChildRecalPart(cp));
|
||||||
}
|
}
|
||||||
|
|
||||||
return isGlassPartRecalPart;
|
return isGlassPartRecalPart;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue