This commit is contained in:
@@ -110,9 +110,9 @@ public class FileSimilarityService {
|
||||
return duplicates;
|
||||
}
|
||||
|
||||
public void hasDuplicatesByHash(String path, Long userId, String mimeType) throws Exception {
|
||||
public void hasDuplicatesByHash(String path, String mimeType) throws Exception {
|
||||
String hash = calculateFileHash(path);
|
||||
List<FileEntity> fileEntityList = fileEntityRepository.findByUserIdAndMimeType(userId, mimeType);
|
||||
List<FileEntity> fileEntityList = fileEntityRepository.findByMimeType(mimeType);
|
||||
|
||||
for (FileEntity file : fileEntityList) {
|
||||
if (calculateFileHash(file.getFilePath()).equals(hash)) {
|
||||
|
||||
Reference in New Issue
Block a user