gpgedit: check for GPGEDIT_RECIPIENT environment variable instead of assuming its existence
This commit is contained in:
parent
61c19eb6cc
commit
a96d241e93
6
gpgedit
6
gpgedit
@ -30,7 +30,11 @@ $editor = 'vim' if ($editor =~ /^\s*$/);
|
||||
|
||||
system($editor, $dfname);
|
||||
|
||||
my $recipient = $ENV{'GPGEDIT_RECIPIENT'};
|
||||
my $recipient = '';
|
||||
if (exists($ENV{'GPGEDIT_RECIPIENT'}))
|
||||
{
|
||||
$recipient = $ENV{'GPGEDIT_RECIPIENT'};
|
||||
}
|
||||
my @cmd = ('gpg', '--encrypt');
|
||||
if ($recipient !~ /^\s*$/)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user