mirror of https://github.com/rancher/ui.git
Fix JS failure when searching through catalog apps if an app is missing the optional description metadata field
This commit is contained in:
parent
b66284d0b6
commit
1a17118e19
|
|
@ -144,7 +144,7 @@ export default Component.extend({
|
|||
return all;
|
||||
}
|
||||
|
||||
return all.filter((tpl) => tpl.name.toLowerCase().includes(search) || tpl.description.toLowerCase().includes(search));
|
||||
return all.filter((tpl) => (tpl.name && tpl.name.toLowerCase().includes(search)) || (tpl.description && tpl.description.toLowerCase().includes(search)));
|
||||
}),
|
||||
|
||||
arrangedContent: computed('matchingSearch.@each.categoryLowerArray', 'category', function() {
|
||||
|
|
|
|||
Loading…
Reference in New Issue