Recipients and unknownRecipients was not ensured to be a list

This commit is contained in:
Markus Braun 2011-07-05 12:32:37 +02:00
parent b4be3c10e2
commit 4340361541

View File

@ -567,6 +567,10 @@ function s:GPGEditRecipients()
" put the recipients in the scratch buffer " put the recipients in the scratch buffer
let recipients=getbufvar(b:corresponding_to, "GPGRecipients") let recipients=getbufvar(b:corresponding_to, "GPGRecipients")
if (type(recipients) != type([]))
unlet recipients
let recipients=[]
endif
for name in recipients for name in recipients
let name=s:GPGIDToName(name) let name=s:GPGIDToName(name)
@ -575,6 +579,10 @@ function s:GPGEditRecipients()
" put the unknown recipients in the scratch buffer " put the unknown recipients in the scratch buffer
let unknownRecipients=getbufvar(b:corresponding_to, "GPGUnknownRecipients") let unknownRecipients=getbufvar(b:corresponding_to, "GPGUnknownRecipients")
if (type(unknownRecipients) != type([]))
unlet unknownRecipients
let unknownRecipients=[]
endif
let syntaxPattern="\\(nonexistingwordinthisbuffer" let syntaxPattern="\\(nonexistingwordinthisbuffer"
for name in unknownRecipients for name in unknownRecipients
let name="!" . name let name="!" . name