From d07805cd54fffff3abb955a7c04c0852e973cbb0 Mon Sep 17 00:00:00 2001 From: _Bastler Date: Tue, 5 Oct 2021 21:17:12 +0200 Subject: [PATCH] fix link text --- .../de/bstly/board/controller/validation/EntryValidator.java | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/main/java/de/bstly/board/controller/validation/EntryValidator.java b/src/main/java/de/bstly/board/controller/validation/EntryValidator.java index 55e2b6f..d7b4ca5 100644 --- a/src/main/java/de/bstly/board/controller/validation/EntryValidator.java +++ b/src/main/java/de/bstly/board/controller/validation/EntryValidator.java @@ -12,14 +12,12 @@ import org.springframework.validation.Validator; import de.bstly.board.model.Entry; import de.bstly.board.model.EntryType; - /** * The Class EntryValidator. */ @Component public class EntryValidator implements Validator { - private UrlValidator urlValidator = new UrlValidator(); /* @@ -44,7 +42,6 @@ public class EntryValidator implements Validator { if (entry.getEntryType() == null) { errors.rejectValue("entrytype", "REQUIRED"); } else if (EntryType.LINK.equals(entry.getEntryType())) { - entry.setText(null); if (!StringUtils.hasText(entry.getUrl())) { errors.rejectValue("url", "REQUIRED"); }