nodebb-plugin-ezoic-infinite 1.4.28 → 1.4.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/public/client.js +0 -15
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nodebb-plugin-ezoic-infinite",
3
- "version": "1.4.28",
3
+ "version": "1.4.29",
4
4
  "description": "Production-ready Ezoic infinite ads integration for NodeBB 4.x",
5
5
  "main": "library.js",
6
6
  "license": "MIT",
package/public/client.js CHANGED
@@ -464,9 +464,7 @@
464
464
  if (!wrap) continue;
465
465
  // Attendre que le wrapper soit dans le DOM puis appeler showAds
466
466
  setTimeout(() => {
467
- if (!false) {
468
467
  callShowAdsWhenReady(id);
469
- }
470
468
  }, 1500);
471
469
  } else {
472
470
  usedSet.add(id);
@@ -488,11 +486,8 @@
488
486
  continue;
489
487
  }
490
488
  if (!(pick.recycled && pick.recycled.wrap)) {
491
- // Ne pas appeler showAds si cet ID a déjà été blacklisté
492
- if (!false) {
493
489
  callShowAdsWhenReady(id);
494
490
  }
495
- }
496
491
  inserted += 1;
497
492
  }
498
493
  return inserted;
@@ -559,11 +554,9 @@
559
554
  }
560
555
 
561
556
  async function runCore() {
562
- console.log('[EZOIC DEBUG] runCore démarré, pageKey:', state.pageKey);
563
557
  patchShowAds();
564
558
 
565
559
  const cfg = await fetchConfig();
566
- console.log('[EZOIC DEBUG] Config récupérée, excluded:', cfg?.excluded);
567
560
  if (!cfg || cfg.excluded) return;
568
561
 
569
562
  initPools(cfg);
@@ -597,8 +590,6 @@
597
590
  }
598
591
  }
599
592
 
600
- console.log('[EZOIC DEBUG] Inserted:', inserted, 'wrappers');
601
-
602
593
  enforceNoAdjacentAds();
603
594
 
604
595
  // If nothing inserted and list isn't in DOM yet (first click), retry a bit
@@ -649,13 +640,11 @@
649
640
  $(window).on('action:ajaxify.start.ezoicInfinite', () => cleanup());
650
641
 
651
642
  $(window).on('action:ajaxify.end.ezoicInfinite', () => {
652
- console.log('[EZOIC DEBUG] ajaxify.end déclenché');
653
643
  state.pageKey = getPageKey();
654
644
  ensureObserver();
655
645
 
656
646
  // Attendre que le DOM soit construit par NodeBB
657
647
  setTimeout(() => {
658
- console.log('[EZOIC DEBUG] Appel waitForEzoicThenRun après 500ms');
659
648
  // Puis attendre que Ezoic soit prêt (comme au chargement initial)
660
649
  waitForEzoicThenRun();
661
650
  }, 500);
@@ -711,11 +700,8 @@
711
700
 
712
701
  (function check() {
713
702
  attempts++;
714
- console.log('[EZOIC DEBUG] waitForEzoic attempt', attempts, 'ezstandalone:', !!window.ezstandalone, 'showAds:', typeof window.ezstandalone?.showAds);
715
-
716
703
  // Vérifier si Ezoic est chargé
717
704
  if (window.ezstandalone && typeof window.ezstandalone.showAds === 'function') {
718
- console.log('[EZOIC DEBUG] Ezoic prêt après', attempts, 'tentatives');
719
705
  // Ezoic est prêt → lancer l'insertion
720
706
  scheduleRun();
721
707
  setTimeout(scheduleRun, 300);
@@ -723,7 +709,6 @@
723
709
  }
724
710
  // Ezoic pas encore prêt
725
711
  if (attempts >= maxAttempts) {
726
- console.warn('[EZOIC DEBUG] Timeout après 10s - Ezoic pas chargé');
727
712
  // Tenter quand même
728
713
  scheduleRun();
729
714
  return;