Skip to content

Commit 72e2b48

Browse files
committed
Use category instead of contenttype
1 parent 46b0b39 commit 72e2b48

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

dups.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,7 @@ async function run() {
3737
goodFolders,
3838
async (folder) => {
3939
const name = folder.name;
40-
const imageFiles = folder.contents.filter(
41-
(file) => file.contenttype === 'image/jpeg'
42-
);
40+
const imageFiles = folder.contents.filter((file) => file.category === 1);
4341
const hashToFilesMap = groupByHash(imageFiles);
4442
const fileGroups = [...hashToFilesMap.values()].filter(
4543
(files) => files.length > 1

intersects.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ async function run() {
3939
const hashesPerName = await pMap(goodFolders, async (f) => {
4040
const name = f.name;
4141
const hashList = f.contents
42-
.filter((f) => f.contenttype === 'image/jpeg')
42+
.filter((f) => f.category === 1)
4343
.map((f) => f.hash);
4444
const hashes = new Set(hashList);
4545
return {name, hashes};

0 commit comments

Comments
 (0)