diff --git a/x-pack/plugins/ingest_manager/public/applications/ingest_manager/components/package_icon.tsx b/x-pack/plugins/ingest_manager/public/applications/ingest_manager/components/package_icon.tsx index c5a0e600b7d50..8ba597a0d377e 100644 --- a/x-pack/plugins/ingest_manager/public/applications/ingest_manager/components/package_icon.tsx +++ b/x-pack/plugins/ingest_manager/public/applications/ingest_manager/components/package_icon.tsx @@ -59,7 +59,7 @@ const usePackageIcon = (packageName: string, version?: string, icons?: Package[' } // Use API to see if package has icons defined - if (!icons && version !== undefined) { + if (!icons && version) { fromPackageInfo(pkgKey) .catch(() => undefined) // ignore API errors .then(fromInput); diff --git a/x-pack/plugins/ingest_manager/public/applications/ingest_manager/sections/epm/hooks/use_local_search.tsx b/x-pack/plugins/ingest_manager/public/applications/ingest_manager/sections/epm/hooks/use_local_search.tsx index 26f1ef6a80271..c81dc15f569fa 100644 --- a/x-pack/plugins/ingest_manager/public/applications/ingest_manager/sections/epm/hooks/use_local_search.tsx +++ b/x-pack/plugins/ingest_manager/public/applications/ingest_manager/sections/epm/hooks/use_local_search.tsx @@ -15,8 +15,6 @@ export function useLocalSearch(packageList: PackageList) { const localSearchRef = useRef(null); useEffect(() => { - if (!packageList.length) return; - const localSearch = new LocalSearch(searchIdField); fieldsToSearch.forEach(field => localSearch.addIndex(field)); localSearch.addDocuments(packageList);