   }
        }
        else
        {
            const set = new Set(db.map(item => JSON.stringify(item)));
            for(let s in newdb)
            {
                let newitm = JSON.stringify(newdb[s]);
                if(set.has(newitm))
                {
                    set.delete(newitm);
                }
            }
            db = Array.from(set).map(item => JSON.parse(item));
        }
        if(dedup && !subtract_existing)
        {
            const set = new Set(db.