[ACA-19] show search libraries hint (#802)

* [ACA-19] show hint on 400 error

* [ACA-19] unit test

* [ACA-19] small change

* [ACA-19] unit test

* [ACA-19] unit tests

* [ACA-19] avoid memory leaks with takeUntil

* [ACA-19] remove comment & formatting

* [ACA-19] update documentation
This commit is contained in:
Suzana Dirla
2018-11-16 14:35:41 +02:00
committed by Denys Vuika
parent ff0891009e
commit dcacbc1210
13 changed files with 343 additions and 24 deletions

View File

@@ -87,8 +87,6 @@ export class SearchInputControlComponent implements OnDestroy {
}
isTermTooShort() {
const alphanumericTerm = this.searchTerm.replace(/[^0-9a-z]/gi, '');
return this.searchTerm.length && alphanumericTerm.length < 2;
return !!(this.searchTerm && this.searchTerm.length < 2);
}
}