From a8df77676466b1c1f3ac08ccaba07789f80b0307 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 12 Aug 2022 16:24:38 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- taxonium_web_client/src/hooks/useSearch.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/taxonium_web_client/src/hooks/useSearch.js b/taxonium_web_client/src/hooks/useSearch.js index f44cff71..ae323fbe 100644 --- a/taxonium_web_client/src/hooks/useSearch.js +++ b/taxonium_web_client/src/hooks/useSearch.js @@ -182,12 +182,11 @@ const useSearch = ({ const { index } = zoomToSearch; let relevant = []; if (index == -1) { - searchSpec.forEach((value) => - { if(searchResults[value.key]){ - relevant.push(...searchResults[searchSpec[index].key]) - } - } - ); + searchSpec.forEach((value) => { + if (searchResults[value.key]) { + relevant.push(...searchResults[searchSpec[index].key]); + } + }); } else { relevant = searchResults[searchSpec[index].key]; }