Skip to content

Commit 4cf69eb

Browse files
committed
101623: Fix reset emit nog working for BrowseByTaxonomyPage
1 parent 9d08cac commit 4cf69eb

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

src/app/browse-by/browse-by-taxonomy-page/browse-by-taxonomy-page.component.spec.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ describe('BrowseByTaxonomyPageComponent', () => {
4747
detail2 = new VocabularyEntryDetail();
4848
detail1.value = 'HUMANITIES and RELIGION';
4949
detail2.value = 'TECHNOLOGY';
50+
detail1.id = 'id-1';
51+
detail2.id = 'id-2';
5052
});
5153

5254
it('should create', () => {

src/app/browse-by/browse-by-taxonomy-page/browse-by-taxonomy-page.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ export class BrowseByTaxonomyPageComponent implements OnInit, OnDestroy {
9898
* @param detail VocabularyEntryDetail to be removed
9999
*/
100100
onDeselect(detail: VocabularyEntryDetail): void {
101-
this.selectedItems = this.selectedItems.filter((entry: VocabularyEntryDetail) => { return entry !== detail; });
101+
this.selectedItems = this.selectedItems.filter((entry: VocabularyEntryDetail) => { return entry.id !== detail.id; });
102102
this.filterValues = this.filterValues.filter((value: string) => { return value !== `${detail.value},equals`; });
103103
this.updateQueryParams();
104104
}

0 commit comments

Comments
 (0)