From 13a0b3098f8800fede184637e60611e814783ff5 Mon Sep 17 00:00:00 2001 From: Will Moss Date: Mon, 22 Jul 2024 02:24:12 +0700 Subject: [PATCH] fix(client): fixed the download feature to download the proper video, not always the first one --- src/App.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/App.js b/src/App.js index 2deff1f..1cc6ec1 100644 --- a/src/App.js +++ b/src/App.js @@ -34,7 +34,7 @@ const App = () => { // Video control - Download the current video const download = () => { - const url = videos[0].url; + const url = videos[visibleIndexes.length === 2 ? visibleIndexes[0] : visibleIndexes[1]].url; const anchor = document.createElement("a"); anchor.href = url;