[zsh] Complete the correct keys

Check the -d option before completing password/note keys to query the
correct database.