From 04aa77253fed64ef4c0a0414bc12dc4e92f3bcbd Mon Sep 17 00:00:00 2001 From: David Granado Date: Fri, 21 Jan 2022 17:46:18 -0600 Subject: [PATCH] Only send search request when string length enough for api expectation. --- ui/component/channelContent/view.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/component/channelContent/view.jsx b/ui/component/channelContent/view.jsx index c3781d3b8..3a5543fdc 100644 --- a/ui/component/channelContent/view.jsx +++ b/ui/component/channelContent/view.jsx @@ -86,7 +86,7 @@ function ChannelContent(props: Props) { React.useEffect(() => { const timer = setTimeout(() => { - if (searchQuery === '' || !claimId) { + if (searchQuery.trim().length < 3 || !claimId) { // In order to display original search results, search results must be set to null. A query of '' should display original results. return setSearchResults(null); } else {