mirror of
https://github.com/ranaldsgift/KefinTweaks.git
synced 2026-11-05 15:52:47 +01:00
Prevent Collection information being added in duplicate
This commit is contained in:
@@ -600,6 +600,15 @@
|
||||
* @param {Object} item - Collection item (BoxSet)
|
||||
*/
|
||||
async function updateCollectionPage(item) {
|
||||
const activePage = document.querySelector('.libraryPage:not(.hide)');
|
||||
if (!activePage) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (activePage.dataset.kefinCollectionPage === 'true') {
|
||||
return;
|
||||
}
|
||||
|
||||
const unplayedItemCount = item.UserData?.UnplayedItemCount || 0;
|
||||
const totalItemCount = item.RecursiveItemCount || item.ChildCount || 0;
|
||||
const playedItemCount = totalItemCount - unplayedItemCount;
|
||||
@@ -621,6 +630,7 @@
|
||||
itemMiscInfoPrimary.appendChild(mediaInfoItemIncomplete);
|
||||
}
|
||||
|
||||
activePage.dataset.kefinCollectionPage = 'true';
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user