]> git.basschouten.com Git - openhab-addons.git/commitdiff
[bsblan] Remove org.apache.commons (#14515)
authorlsiepel <leosiepel@gmail.com>
Fri, 10 Mar 2023 22:37:45 +0000 (23:37 +0100)
committerGitHub <noreply@github.com>
Fri, 10 Mar 2023 22:37:45 +0000 (23:37 +0100)
* Replace org.apache.commons with org.unbescape

Signed-off-by: lsiepel <leosiepel@gmail.com>
bundles/org.openhab.binding.bsblan/pom.xml
bundles/org.openhab.binding.bsblan/src/main/java/org/openhab/binding/bsblan/internal/helper/BsbLanParameterConverter.java

index f2ad5a442b66eebd6e99ebf0cadb0312cd351a93..bfe9c5d1244761264a4d663dd8fa6dc3f8c57d9b 100644 (file)
 
   <name>openHAB Add-ons :: Bundles :: BSB-LAN Binding</name>
 
+  <dependencies>
+    <dependency>
+      <groupId>org.unbescape</groupId>
+      <artifactId>unbescape</artifactId>
+      <version>1.1.6.RELEASE</version>
+      <scope>compile</scope>
+    </dependency>
+  </dependencies>
+
 </project>
index 3afd4369e0ab21fec9df3fa1cab4d185911ee247..fa48aa7c8e3a76dc18a959ffcf21590a8786d725 100644 (file)
@@ -14,7 +14,6 @@ package org.openhab.binding.bsblan.internal.helper;
 
 import static org.openhab.binding.bsblan.internal.BsbLanBindingConstants.*;
 
-import org.apache.commons.lang3.StringEscapeUtils;
 import org.eclipse.jdt.annotation.NonNullByDefault;
 import org.eclipse.jdt.annotation.Nullable;
 import org.openhab.binding.bsblan.internal.api.dto.BsbLanApiParameterDTO;
@@ -26,6 +25,7 @@ import org.openhab.core.types.Command;
 import org.openhab.core.types.State;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
+import org.unbescape.html.HtmlEscape;
 
 /**
  * The {@link BsbLanParameterHandler} is responsible for updating the data, which are
@@ -75,7 +75,7 @@ public class BsbLanParameterConverter {
     }
 
     private static State getStateForUnitChannel(BsbLanApiParameterDTO parameter) {
-        String value = StringEscapeUtils.unescapeHtml4(parameter.unit);
+        String value = HtmlEscape.unescapeHtml(parameter.unit);
         return new StringType(value);
     }