mirror of
https://github.com/anidl/multi-downloader-nx.git
synced 2026-04-21 08:21:56 +00:00
Prevent duplicate archive entries
This commit is contained in:
parent
af8ebbb92c
commit
1cd8c6ed19
1 changed files with 2 additions and 0 deletions
|
|
@ -33,6 +33,8 @@ const addToArchive = (kind: {
|
|||
|
||||
if (Object.prototype.hasOwnProperty.call(data, kind.service)) {
|
||||
const items = kind.service === 'crunchy' ? data[kind.service][kind.type] : data[kind.service][kind.type];
|
||||
if (items.findIndex(a => a.id === ID) < 0) // Prevent duplicate
|
||||
return;
|
||||
items.push({
|
||||
id: ID,
|
||||
already: []
|
||||
|
|
|
|||
Loading…
Reference in a new issue