From ba03cde4692913e53a9f7857d8f58b3c0329fdce Mon Sep 17 00:00:00 2001 From: Jake Esser Date: Tue, 31 Oct 2023 17:26:54 +0100 Subject: [PATCH] Removed space from HeaderValue parsing and added trimming --- .../java/org/javawebstack/http/router/util/HeaderValue.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/org/javawebstack/http/router/util/HeaderValue.java b/src/main/java/org/javawebstack/http/router/util/HeaderValue.java index 0e136cf..1dea862 100644 --- a/src/main/java/org/javawebstack/http/router/util/HeaderValue.java +++ b/src/main/java/org/javawebstack/http/router/util/HeaderValue.java @@ -9,10 +9,10 @@ public class HeaderValue { private final Map directives = new HashMap<>(); public HeaderValue(String source) { - String[] spl = source.split("; "); - value = spl[0]; + String[] spl = source.split(";"); + value = spl[0].trim(); for(int i=1; i