Fix regression for username fallback
While usernames were now picked up correctly as a fallback from the filename if none were present in the fields themselves, if there were any in the fields the program would return an empty string. This fixes it for both cases, the username existing in the entry fields or only in the filename. Entry fields will still take precedence.
This commit is contained in:
parent
2236d7fec8
commit
6dc0cd6d16
1 changed files with 2 additions and 0 deletions
|
@ -208,6 +208,8 @@ show_username() {
|
|||
result=$(_p_get_field "$1" "${PASS_USERNAME_FIELD}")
|
||||
if [ -z "$result" ]; then
|
||||
echo "${1##*/}"
|
||||
else
|
||||
echo "$result"
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue