This commit is contained in:
sirjonasxx 2021-01-17 05:02:46 +01:00
parent cd109c9b4b
commit 8f99661789

View File

@ -94,8 +94,6 @@ public class UiLoggerController implements Initializable {
ArrayList<Element> elements = new ArrayList<>(); ArrayList<Element> elements = new ArrayList<>();
String expr = packet.toExpression(isIncoming ? HMessage.Direction.TOCLIENT : HMessage.Direction.TOSERVER);
lblHarbleAPI.setText("Messages: " + (HarbleAPIFetcher.HARBLEAPI == null ? "False" : "True")); lblHarbleAPI.setText("Messages: " + (HarbleAPIFetcher.HARBLEAPI == null ? "False" : "True"));
if ((viewMessageName || viewMessageHash) && HarbleAPIFetcher.HARBLEAPI != null) { if ((viewMessageName || viewMessageHash) && HarbleAPIFetcher.HARBLEAPI != null) {
HarbleAPI api = HarbleAPIFetcher.HARBLEAPI; HarbleAPI api = HarbleAPIFetcher.HARBLEAPI;
@ -146,11 +144,14 @@ public class UiLoggerController implements Initializable {
} }
} }
if (packet.length() <= 2000) {
String expr = packet.toExpression(isIncoming ? HMessage.Direction.TOCLIENT : HMessage.Direction.TOSERVER);
String cleaned = cleanTextContent(expr); String cleaned = cleanTextContent(expr);
if (cleaned.equals(expr)) { if (cleaned.equals(expr)) {
if (!expr.equals("") && displayStructure && packet.length() <= 2000) if (!expr.equals("") && displayStructure)
elements.add(new Element("\n" + cleanTextContent(expr), "structure")); elements.add(new Element("\n" + cleanTextContent(expr), "structure"));
} }
}
elements.add(new Element("\n--------------------\n", "")); elements.add(new Element("\n--------------------\n", ""));