From 90360a312dfa79f6c04824d55e38aaa2b651f505 Mon Sep 17 00:00:00 2001 From: Hicham Boushaba Date: Mon, 9 Sep 2024 11:34:30 +0100 Subject: [PATCH] Remove Android dependency from fastStripHtml function This just makes it easier to use it in tests without any mocks. --- .../src/main/java/org/wordpress/android/util/HtmlUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/WordPressUtils/src/main/java/org/wordpress/android/util/HtmlUtils.java b/WordPressUtils/src/main/java/org/wordpress/android/util/HtmlUtils.java index e91024b12..f59c3b704 100644 --- a/WordPressUtils/src/main/java/org/wordpress/android/util/HtmlUtils.java +++ b/WordPressUtils/src/main/java/org/wordpress/android/util/HtmlUtils.java @@ -37,7 +37,7 @@ public static String stripHtml(final String text) { * @return String without HTML */ public static String fastStripHtml(String str) { - if (TextUtils.isEmpty(str)) { + if (str == null || str.isEmpty()) { return str; }