From 942c1e01dc52859721eeb45bcc191810b36a7cd5 Mon Sep 17 00:00:00 2001 From: Bill Thornton Date: Sun, 18 Aug 2024 01:29:49 -0400 Subject: [PATCH] Fix home section resume error --- src/components/homesections/homesections.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/components/homesections/homesections.js b/src/components/homesections/homesections.js index 3f363fee0f8..43761d2447d 100644 --- a/src/components/homesections/homesections.js +++ b/src/components/homesections/homesections.js @@ -131,9 +131,11 @@ export function resume(elem, options) { const elems = elem.querySelectorAll('.itemsContainer'); const promises = []; - for (let i = 0, length = elems.length; i < length; i++) { - promises.push(elems[i].resume(options)); - } + Array.prototype.forEach.call(elems, section => { + if (section.resume) { + promises.push(section.resume(options)); + } + }); return Promise.all(promises); }