Skip to content

Commit

Permalink
fix: remove usage of apache commons StringUtils
Browse files Browse the repository at this point in the history
Signed-off-by: Andre Dietisheim <[email protected]>
  • Loading branch information
adietish committed Oct 22, 2024
1 parent 4259608 commit 4e1b213
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
import com.intellij.openapi.components.Service;
import com.intellij.openapi.components.State;
import com.intellij.openapi.components.Storage;
import com.intellij.openapi.util.text.StringUtil;
import com.intellij.util.xmlb.XmlSerializerUtil;
import com.redhat.devtools.intellij.telemetry.core.service.Event;
import org.apache.commons.lang.StringUtils;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

Expand Down Expand Up @@ -107,7 +107,7 @@ private Count createOrUpdateCount(Event event) {
}

private Count toCount(String string) {
if (StringUtils.isEmpty(string)) {
if (StringUtil.isEmpty(string)) {
return null;
}
String[] split = string.split(COUNT_VALUES_SEPARATOR);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
******************************************************************************/
package com.redhat.devtools.intellij.telemetry.core.util;

import org.apache.commons.lang.StringUtils;
import com.intellij.openapi.util.text.StringUtil;

import java.util.regex.Pattern;
import java.util.regex.PatternSyntaxException;
Expand Down Expand Up @@ -60,7 +60,7 @@ private BasicGlobPattern(Pattern globPattern) {
}

public boolean matches(String toMatch) {
if (StringUtils.isEmpty(toMatch)) {
if (StringUtil.isEmpty(toMatch)) {
return false;
}
return globPattern.matcher(toMatch).matches();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
******************************************************************************/
package com.redhat.devtools.intellij.telemetry.core.util;

import org.apache.commons.lang.StringUtils;
import com.intellij.openapi.util.text.StringUtil;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

Expand Down Expand Up @@ -60,7 +60,7 @@ public static void write(String content, Path file) throws IOException {
}

public static boolean isFileUrl(String url) {
return !StringUtils.isEmpty(url)
return !StringUtil.isEmpty(url)
&& url.startsWith(FILE_URL_PREFIX);
}

Expand Down

0 comments on commit 4e1b213

Please sign in to comment.