mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
fixed PY-6907 Paste leads to syntactically incorrect code in case of dedent in copied text
This commit is contained in:
+1
-1
@@ -156,9 +156,9 @@ public class CopyPasteIndentProcessor implements CopyPastePostProcessor<IndentTr
|
||||
for (String s : split) {
|
||||
currentIndent = s.length() - s.trim().length();
|
||||
if (split[0].equals(s) ) {
|
||||
firstIndent = currentIndent;
|
||||
if (currentIndent == 0)
|
||||
currentIndent = textBeforeFirstLine.length();
|
||||
firstIndent = currentIndent;
|
||||
}
|
||||
if (!StringUtil.isEmptyOrSpaces(s) && firstIndent > currentIndent)
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user