From eb43621b7423094d3cac44d63f6bbead72feaff9 Mon Sep 17 00:00:00 2001 From: vladp Date: Wed, 15 Apr 2026 09:51:18 +0700 Subject: [PATCH] dev add geo country service --- .../java/ru/soune/nocopy/handler/ViolationHandler.java | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/main/java/ru/soune/nocopy/handler/ViolationHandler.java b/src/main/java/ru/soune/nocopy/handler/ViolationHandler.java index f2ad280..f900c90 100644 --- a/src/main/java/ru/soune/nocopy/handler/ViolationHandler.java +++ b/src/main/java/ru/soune/nocopy/handler/ViolationHandler.java @@ -119,14 +119,9 @@ public class ViolationHandler implements RequestHandler { List content = violationPage.getContent(); List violationDtos = new ArrayList<>(); -// List violationDtos = violationPage.getContent() -// .stream() -// .map(ViolationResponse.ViolationDto::fromEntity) -// .toList(); - for (Violation violation : content) { ViolationResponse.ViolationDto violationDto = ViolationResponse.ViolationDto.fromEntity(violation); - violationDto.setCountry(geoCountryService.getCountry(violation.getUrl())); + violationDto.setCountry(geoCountryService.getCountry(violation.getPageUrl())); violationDtos.add(violationDto); }