Greasy Fork is available in English.

Youtube - Search While Watching Video

Search YouTube without interrupting the video, by loading the search results in the related video bar

< Σχολιασμός για τον κώδικα Youtube - Search While Watching Video

Ερώτηση/σχόλιο

§
Δημοσιεύτηκε: 02/03/2024

Request Update:

Change


        function isPlayerAvailable() {
            script.ytplayer = getVideoPlayer();
            return script.ytplayer !== null && script.ytplayer.getVideoData().video_id;
        }

to


        function isPlayerAvailable() {
            script.ytplayer = getVideoPlayer();
            return script.ytplayer && typeof script.ytplayer.getVideoData === 'function' && script.ytplayer.getVideoData().video_id;
        }

getVideoData might be assigned after the DOM element is inserted. At that time, error will occur.

CptmathixΔημιουργός
§
Δημοσιεύτηκε: 02/03/2024

Thank you for reporting, updated!

Δημοσίευση απάντησης

Συνδεθείτε για να δημοσιεύσετε μια απάντηση.