Fix duplicate icon and user tag on page reload by adding class and duplicate check
All checks were successful
All checks were successful
This commit is contained in:
@@ -462,7 +462,7 @@ function updateDownloadCard(card, download) {
|
||||
|
||||
// Add new right-side container with user badge and logo
|
||||
const header = card.querySelector('.download-header');
|
||||
if (header) {
|
||||
if (header && !header.querySelector('.download-header-right')) {
|
||||
const rightSide = document.createElement('div');
|
||||
rightSide.className = 'download-header-right';
|
||||
|
||||
@@ -490,7 +490,7 @@ function updateDownloadCard(card, download) {
|
||||
|
||||
if (download.client) {
|
||||
const clientLogoWrapper = document.createElement('span');
|
||||
clientLogoWrapper.className = 'download-client-logo-wrapper';
|
||||
clientLogoWrapper.className = 'download-client-logo-wrapper download-card-logo-wrapper';
|
||||
|
||||
const clientLogo = document.createElement('img');
|
||||
clientLogo.className = 'download-client-logo';
|
||||
|
||||
Reference in New Issue
Block a user