Skip to content

Commit

Permalink
Remove-var-usages
Browse files Browse the repository at this point in the history
Co-Authored-By: Jtfk <10415768+jtfk@users.noreply.github.com>
  • Loading branch information
ShareASmile and Jtfk committed Dec 10, 2023
1 parent 4aab1a3 commit a969c03
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@ public Description getCommentText() throws ParsingException {
final String htmlText = JsonUtils.getString(item, "text");
try {
final Document doc = Jsoup.parse(htmlText);
final var text = doc.body().text();
final String text = doc.body().text();
return new Description(text, Description.PLAIN_TEXT);
} catch (final Exception e) {
final var text = htmlText.replaceAll("(?s)<[^>]*>(\\s*<[^>]*>)*", "");
final String text = htmlText.replaceAll("(?s)<[^>]*>(\\s*<[^>]*>)*", "");
return new Description(text, Description.PLAIN_TEXT);
}
}
Expand Down

0 comments on commit a969c03

Please sign in to comment.