Invidious is an alternative front-end to YouTube
fix potential memory leak
ChunkyProgrammer090b470bfcad
diff --git a/src/invidious/routes/api/v1/search.cr b/src/invidious/routes/api/v1/search.crindex a65571ea..2922b060 100644--- a/src/invidious/routes/api/v1/search.cr+++ b/src/invidious/routes/api/v1/search.cr@@ -37,6 +37,7 @@ module Invidious::Routes::API::V1::Searchurl = "/complete/search?client=youtube&hl=en&gl=#{region}&q=#{URI.encode_www_form(query)}&gs_ri=youtube&ds=yt"response = client.get(url).body+ client.closebody = JSON.parse(response[19..-2]).as_asuggestions = body[1].as_a[0..-2]