From 0a855fc4c4ecbb6fa8a49581d8b228c7efbaad70 Mon Sep 17 00:00:00 2001 From: ddwightx Date: Thu, 24 Mar 2022 12:48:46 -0400 Subject: [PATCH] Fixed bug with a variable name error popping up unexpectedly when trying to insert a variable tag (cherry picked from commit e127a6ae056cef94c4524daef6d7db2329d6a262) --- build.gradle | 2 +- .../models/rules/wizard/vars/EventVariableTagWizardModel.java | 1 + .../models/rules/wizard/vars/GlobalVariableTagWizardModel.java | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 65c49e6..bab84e1 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ plugins { } group 'com.synfron.reshaper.burp' -version '1.8.0' +version '1.8.1' targetCompatibility = '15' sourceCompatibility = '15' diff --git a/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/EventVariableTagWizardModel.java b/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/EventVariableTagWizardModel.java index 98d63a6..d250ac6 100644 --- a/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/EventVariableTagWizardModel.java +++ b/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/EventVariableTagWizardModel.java @@ -31,6 +31,7 @@ public EventVariableTagWizardModel(List entries) { .distinct() .sorted(String::compareToIgnoreCase) .collect(Collectors.toList()); + variableName = variableNames.stream().findFirst().orElse(null); } private void propertyChanged(String name, Object value) { diff --git a/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/GlobalVariableTagWizardModel.java b/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/GlobalVariableTagWizardModel.java index 8d165ef..5bd8917 100644 --- a/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/GlobalVariableTagWizardModel.java +++ b/src/main/java/synfron/reshaper/burp/ui/models/rules/wizard/vars/GlobalVariableTagWizardModel.java @@ -33,6 +33,7 @@ public GlobalVariableTagWizardModel(List entries) { .distinct() .sorted(String::compareToIgnoreCase) .collect(Collectors.toList()); + variableName = variableNames.stream().findFirst().orElse(null); } private void propertyChanged(String name, Object value) {