mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-10-01 01:26:01 -04:00
Prevent duplicate characters in "Also choose from" field of password generator (#9803)
* Fixes #9797
This commit is contained in:
parent
07232f04c0
commit
ce01f6d7cd
@ -261,8 +261,10 @@ QVector<PasswordGroup> PasswordGenerator::passwordGroups() const
|
||||
if (!m_custom.isEmpty()) {
|
||||
PasswordGroup group;
|
||||
|
||||
for (auto ch : m_custom) {
|
||||
group.append(ch);
|
||||
for (const auto& ch : m_custom) {
|
||||
if (!group.contains(ch)) {
|
||||
group.append(ch);
|
||||
}
|
||||
}
|
||||
|
||||
passwordGroups.append(group);
|
||||
|
Loading…
Reference in New Issue
Block a user