diff --git a/client/src/pages/VideoPage.tsx b/client/src/pages/VideoPage.tsx index 8ed4250..2d5f21b 100644 --- a/client/src/pages/VideoPage.tsx +++ b/client/src/pages/VideoPage.tsx @@ -85,17 +85,8 @@ export default function VideoPage() { }; const navigateToVideo = (direction: 'next' | 'prev') => { - console.log('Navigate clicked:', direction); - console.log('All videos length:', allVideos.length); - console.log('Current video:', currentVideo?.title); - const currentIndex = getCurrentVideoIndex(); - console.log('Current index:', currentIndex); - - if (currentIndex === -1) { - console.log('Video not found in list'); - return; - } + if (currentIndex === -1) return; let newIndex; if (direction === 'next') { @@ -105,8 +96,6 @@ export default function VideoPage() { } const newVideo = allVideos[newIndex]; - console.log('New video:', newVideo?.title); - if (newVideo) { setLocation(`/video/${newVideo.id}`); } @@ -429,7 +418,6 @@ export default function VideoPage() { onClick={(e) => { e.preventDefault(); e.stopPropagation(); - console.log('Prev button clicked'); navigateToVideo('prev'); }} className="absolute left-2 top-1/2 transform -translate-y-1/2 bg-black/90 hover:bg-black text-white border-none p-4 rounded-full shadow-xl flex items-center justify-center" @@ -443,7 +431,6 @@ export default function VideoPage() { onClick={(e) => { e.preventDefault(); e.stopPropagation(); - console.log('Next button clicked'); navigateToVideo('next'); }} className="absolute right-2 top-1/2 transform -translate-y-1/2 bg-black/90 hover:bg-black text-white border-none p-4 rounded-full shadow-xl flex items-center justify-center"