@k03mad/ip2geo 10.1.0 → 10.1.1
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.
- package/app/helpers/cache.js +1 -3
- package/package.json +1 -1
package/app/helpers/cache.js
CHANGED
|
@@ -221,6 +221,7 @@ export const pruneCache = async (cacheDir, cacheFileSeparator, cacheFileNewline)
|
|
|
221
221
|
const uniqSorted = [...new Set(dataArrRemoveEmpty)]
|
|
222
222
|
.sort((a, b) => cacheLineToNum(a) - cacheLineToNum(b));
|
|
223
223
|
|
|
224
|
+
getArrayDups(dataArrRemoveEmpty).forEach(dup => duplicates.add(dup));
|
|
224
225
|
const dupsIp = getArrayDups(uniqSorted.map(elem => elem.split(cacheFileSeparator)[0]));
|
|
225
226
|
|
|
226
227
|
const removeDiffs = uniqSorted.filter(elem => {
|
|
@@ -240,9 +241,6 @@ export const pruneCache = async (cacheDir, cacheFileSeparator, cacheFileNewline)
|
|
|
240
241
|
} else {
|
|
241
242
|
await fs.rm(fullFilePath);
|
|
242
243
|
}
|
|
243
|
-
|
|
244
|
-
const dups = getArrayDups(dataArrRemoveEmpty);
|
|
245
|
-
dups.forEach(dup => duplicates.add(dup));
|
|
246
244
|
}));
|
|
247
245
|
|
|
248
246
|
return {
|