From 053e8dd106ce4ccc9e961350c0c87b9fcd5610dc Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Mon, 30 Jul 2012 11:58:17 +0200 Subject: [PATCH] Skip non-existing properties. --- .../net/pterodactylus/demoscenemusic/page/admin/AdminBasePage.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/net/pterodactylus/demoscenemusic/page/admin/AdminBasePage.java b/src/main/java/net/pterodactylus/demoscenemusic/page/admin/AdminBasePage.java index 2f4d526..66ba7bc 100644 --- a/src/main/java/net/pterodactylus/demoscenemusic/page/admin/AdminBasePage.java +++ b/src/main/java/net/pterodactylus/demoscenemusic/page/admin/AdminBasePage.java @@ -73,7 +73,10 @@ public class AdminBasePage extends BasePage { propertiesToDelete.add(property.getKey()); continue; } - String value = request.getServletRequest().getParameter("value." + property.getKey()).trim(); + String value = request.getServletRequest().getParameter("value." + property.getKey()); + if (value == null) { + continue; + } object.getProperties().set(property.getKey(), value); } -- 2.7.4