mirror of
https://github.com/iv-org/invidious.git
synced 2025-05-02 06:26:27 -04:00
fix incorrect use of setinterval in js
This commit is contained in:
parent
c28b1f6fb9
commit
5a08dfa72f
2 changed files with 4 additions and 4 deletions
|
@ -272,7 +272,7 @@ function get_reddit_comments(retries) {
|
|||
|
||||
xhr.onerror = function () {
|
||||
console.log('Pulling comments failed... ' + retries + '/5');
|
||||
setInterval(function () { get_reddit_comments(retries - 1) }, 1000);
|
||||
setTimeout(function () { get_reddit_comments(retries - 1) }, 1000);
|
||||
}
|
||||
|
||||
xhr.ontimeout = function () {
|
||||
|
@ -346,7 +346,7 @@ function get_youtube_comments(retries) {
|
|||
comments.innerHTML =
|
||||
'<h3 style="text-align:center"><div class="loading"><i class="icon ion-ios-refresh"></i></div></h3>';
|
||||
console.log('Pulling comments failed... ' + retries + '/5');
|
||||
setInterval(function () { get_youtube_comments(retries - 1) }, 1000);
|
||||
setTimeout(function () { get_youtube_comments(retries - 1) }, 1000);
|
||||
}
|
||||
|
||||
xhr.ontimeout = function () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue