From da65e59b8e67bc34dee9b2210cc5e54c2285129f Mon Sep 17 00:00:00 2001 From: Suzana Dirla Date: Tue, 12 Mar 2019 14:24:27 +0200 Subject: [PATCH] [ACA-2264] fix loading on search (#1011) - do nothing on null built query --- .../search/search-results/search-results.component.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/app/components/search/search-results/search-results.component.ts b/src/app/components/search/search-results/search-results.component.ts index 80c798134..9067e9957 100644 --- a/src/app/components/search/search-results/search-results.component.ts +++ b/src/app/components/search/search-results/search-results.component.ts @@ -109,9 +109,11 @@ export class SearchResultsComponent extends PageComponent implements OnInit { this.sorting = this.getSorting(); this.subscriptions.push( - this.queryBuilder.updated.subscribe(() => { - this.sorting = this.getSorting(); - this.isLoading = true; + this.queryBuilder.updated.subscribe(query => { + if (query) { + this.sorting = this.getSorting(); + this.isLoading = true; + } }), this.queryBuilder.executed.subscribe(data => {