Skip to content

Commit

Permalink
getCollectionElements: Added missing return statement
Browse files Browse the repository at this point in the history
  • Loading branch information
alexiglesias93 committed Oct 10, 2021
1 parent 019c297 commit 8fc502b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@finsweet/ts-utils",
"version": "0.18.0",
"version": "0.18.1",
"description": "Typescript utils for custom Webflow projects.",
"main": "index.ts",
"module": "index.ts",
Expand Down
2 changes: 1 addition & 1 deletion webflow/getCollectionElements.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,6 @@ export function getCollectionElements(
referenceElement.querySelector<CollectionListElement>(`.${list}`) ||
referenceElement.closest<CollectionListElement>(`.${list}`);

if (target === 'items') [...(collectionList?.children || [])] as CollectionItemElement[];
if (target === 'items') return [...(collectionList?.children || [])] as CollectionItemElement[];
if (target === 'list') return collectionList;
}

0 comments on commit 8fc502b

Please sign in to comment.