Allow references in part of a field

When a field value is of the form ...{REF:...}...
Then:

* Auto-type does not work with that field
* References to this field are not properly resolved

This commit fixes both issues.
This commit is contained in:
Benoit Mortgat 2018-03-05 17:02:02 +01:00 committed by TheZ3ro
parent 5f9f27604b
commit 18628612b2

View File

@ -801,27 +801,27 @@ QString Entry::resolvePlaceholderRecursive(const QString& placeholder, int maxDe
if (placeholderType(title()) == PlaceholderType::Title) {
return title();
}
return resolvePlaceholderRecursive(title(), maxDepth - 1);
return resolveMultiplePlaceholdersRecursive(title(), maxDepth - 1);
case PlaceholderType::UserName:
if (placeholderType(username()) == PlaceholderType::UserName) {
return username();
}
return resolvePlaceholderRecursive(username(), maxDepth - 1);
return resolveMultiplePlaceholdersRecursive(username(), maxDepth - 1);
case PlaceholderType::Password:
if (placeholderType(password()) == PlaceholderType::Password) {
return password();
}
return resolvePlaceholderRecursive(password(), maxDepth - 1);
return resolveMultiplePlaceholdersRecursive(password(), maxDepth - 1);
case PlaceholderType::Notes:
if (placeholderType(notes()) == PlaceholderType::Notes) {
return notes();
}
return resolvePlaceholderRecursive(notes(), maxDepth - 1);
return resolveMultiplePlaceholdersRecursive(notes(), maxDepth - 1);
case PlaceholderType::Url:
if (placeholderType(url()) == PlaceholderType::Url) {
return url();
}
return resolvePlaceholderRecursive(url(), maxDepth - 1);
return resolveMultiplePlaceholdersRecursive(url(), maxDepth - 1);
case PlaceholderType::UrlWithoutScheme:
case PlaceholderType::UrlScheme:
case PlaceholderType::UrlHost: