This commit is contained in:
Zack Arnett 2020-02-16 18:19:28 -05:00 committed by GitHub
parent f4eb3380b4
commit 363f548f13
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -90,7 +90,7 @@ const calcPoints = (
let last = [average(first), lastValue(first)];
const getCoords = (item, i, offset = 0, depth = 1) => {
if (depth > 1) {
if (depth > 1 && item) {
return item.forEach((subItem, index) =>
getCoords(subItem, i, index, depth - 1)
);