diff --git a/media-domain/src/main/java/nl/vpro/domain/media/search/MediaFormText.java b/media-domain/src/main/java/nl/vpro/domain/media/search/MediaFormText.java index 0cd82c6c8..2bb19ae5f 100644 --- a/media-domain/src/main/java/nl/vpro/domain/media/search/MediaFormText.java +++ b/media-domain/src/main/java/nl/vpro/domain/media/search/MediaFormText.java @@ -95,7 +95,7 @@ public String getUnQuotedValue() { } private static final Pattern PREPARSE = Pattern.compile("[^\\p{IsAlphabetic}&!+\\-\\d\\s]"); - private static final Pattern AFTERPARSE = Pattern.compile("[^\\p{IsAlphabetic}\\-\\d\\s]"); + private static final Pattern AFTERPARSE = Pattern.compile("[^\\p{IsAlphabetic}+\\-\\d\\s]"); private String getCleanText() { String lower = getUnQuotedValue().toLowerCase(); diff --git a/media-domain/src/test/java/nl/vpro/domain/media/search/MediaFormTest.java b/media-domain/src/test/java/nl/vpro/domain/media/search/MediaFormTest.java index 001b3677e..f7fb1ef52 100644 --- a/media-domain/src/test/java/nl/vpro/domain/media/search/MediaFormTest.java +++ b/media-domain/src/test/java/nl/vpro/domain/media/search/MediaFormTest.java @@ -111,7 +111,7 @@ void ANDandNOT() { assertThat(parseANDandNOT("auto and fiets")).isEqualTo("+auto +fiets"); assertThat(parseANDandNOT("auto&fiets")).isEqualTo("+auto +fiets"); assertThat(parseANDandNOT("auto & ! fiets")).isEqualTo("+auto -fiets"); - + assertThat(parseANDandNOT("+auto +fiets")).isEqualTo("+auto +fiets"); } @Test