nodebb-plugin-ezoic-infinite 1.4.29 → 1.4.30

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 +2 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nodebb-plugin-ezoic-infinite",
3
- "version": "1.4.29",
3
+ "version": "1.4.30",
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
@@ -470,6 +470,8 @@
470
470
  usedSet.add(id);
471
471
  wrap = insertAfter(el, id, kindClass, afterPos);
472
472
  if (!wrap) continue;
473
+ // Micro-délai pour laisser le DOM se synchroniser
474
+ setTimeout(() => callShowAdsWhenReady(id), 10);
473
475
  }
474
476
 
475
477
  liveArr.push({ id, wrap });
@@ -485,9 +487,6 @@
485
487
  }
486
488
  continue;
487
489
  }
488
- if (!(pick.recycled && pick.recycled.wrap)) {
489
- callShowAdsWhenReady(id);
490
- }
491
490
  inserted += 1;
492
491
  }
493
492
  return inserted;