From f97f2e392985c1d25528eafb38cc9c67b2b3f313 Mon Sep 17 00:00:00 2001 From: Mark van Seventer Date: Sun, 26 Mar 2023 18:32:34 -0400 Subject: [PATCH] fix: Nested collections: fix collection URL variable (#665) --- packages/core/src/components/Collection/Collection.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/packages/core/src/components/Collection/Collection.tsx b/packages/core/src/components/Collection/Collection.tsx index 91032fb0..dd033429 100644 --- a/packages/core/src/components/Collection/Collection.tsx +++ b/packages/core/src/components/Collection/Collection.tsx @@ -89,10 +89,7 @@ const CollectionView = ({ let url = 'fields' in collection && collection.create ? getNewEntryUrl(collectionName) : ''; if (url && filterTerm) { - url = getNewEntryUrl(collectionName); - if (filterTerm) { - url = `${newEntryUrl}?path=${filterTerm}`; - } + url = `${url}?path=${filterTerm}`; } return url;