SPARK-2374: TranslatorPlugin: don't clear body if translation failed

This commit is contained in:
Sergey Ponomarev
2025-10-20 17:58:38 +03:00
committed by Guus der Kinderen
parent 7a933d7db0
commit cc425f8a86

View File

@ -81,7 +81,6 @@ public class TranslatorPlugin implements Plugin {
String currentBody = message.getBody();
Language lang = (Language) translatorBox.getSelectedItem();
if (lang != null && lang != Language.NONE) {
message.setBody(null);
try {
currentBody = TranslatorUtil.translate(currentBody, lang);
transcriptWindow.insertNotificationMessage("-> "+currentBody, Color.gray);