Fix a bug in command "Remove Consecutive Duplicate Lines"

...while the last line's prefix is the content of its previous line.

Fix #5462
pull/5467/head
Don HO 2019-03-29 02:33:23 +01:00
parent 198cf90c16
commit 0467b7d6cd
No known key found for this signature in database
GPG Key ID: 6C429F1D8D84F46E
1 changed files with 1 additions and 1 deletions

View File

@ -1414,7 +1414,7 @@ void Notepad_plus::removeDuplicateLines()
_findReplaceDlg.processAll(ProcessReplaceAll, &env, true);
// remove the last line if it's a duplicate line.
env._str2Search = TEXT("^(.+)\\r?\\n(\\1)");
env._str2Search = TEXT("^(.+)\\r?\\n(\\1)$");
env._str4Replace = TEXT("\\1");
env._searchType = FindRegex;
_findReplaceDlg.processAll(ProcessReplaceAll, &env, true);