dev email send when tokens not found
Test Workflow / test (push) Successful in 3s

This commit is contained in:
vladp
2026-03-31 14:43:34 +07:00
parent d7874aa37a
commit 69e758a710
3 changed files with 13 additions and 4 deletions
@@ -8,6 +8,7 @@ import org.springframework.stereotype.Service;
import ru.soune.nocopy.entity.file.FileEntity;
import ru.soune.nocopy.entity.file.ImageHashEntity;
import ru.soune.nocopy.repository.ImageHashRepository;
import ru.soune.nocopy.service.file.cloud.CloudStorageService;
import java.io.File;
import java.io.IOException;
@@ -22,8 +23,10 @@ public class ImageHashService {
private final ImageHashRepository repository;
private final CloudStorageService cloudStorageService;
public Map<String, Long> calculateHash(Path imagePath) throws IOException {
File file = imagePath.toFile();
File file = cloudStorageService.readFileFromStorageByPath(imagePath.toString());
PHash pHash = PerceptualHashHelper.INSTANCE.generateDCTPerceptualHash(file);