DeepL: prevent extra newline

This commit is contained in:
M66B 2021-05-21 11:55:28 +02:00
parent 54c9fbaa16
commit ac9f83241c
1 changed files with 1 additions and 1 deletions

View File

@ -2024,7 +2024,7 @@ public class FragmentCompose extends FragmentBase {
// Insert translated text // Insert translated text
StringBuilder sb = new StringBuilder("\n"); StringBuilder sb = new StringBuilder("\n");
if (paragraph.second == edit.length() || if (paragraph.second != edit.length() &&
edit.charAt(paragraph.second) != '\n') edit.charAt(paragraph.second) != '\n')
sb.append('\n'); sb.append('\n');
edit.insert(paragraph.second, sb + translated); edit.insert(paragraph.second, sb + translated);