Replace System.getProperties().remove(x) with System.clearProperty(x)

This commit migrates to the not-so-new System.clearProperty() method
introduced in Java 1.5.
This commit is contained in:
Sam Brannen
2023-12-06 17:11:46 +01:00
parent f14b122c9c
commit 438c3818cc
7 changed files with 19 additions and 19 deletions

View File

@@ -264,7 +264,7 @@ public abstract class WebUtils {
Assert.notNull(servletContext, "ServletContext must not be null");
String param = servletContext.getInitParameter(WEB_APP_ROOT_KEY_PARAM);
String key = (param != null ? param : DEFAULT_WEB_APP_ROOT_KEY);
System.getProperties().remove(key);
System.clearProperty(key);
}
/**