forked from the-distro/channel-scripts
Merge pull request #37 from NixOS/fixup-new-chan
curRelease: guard against missing channel
This commit is contained in:
commit
7a681103b2
|
@ -112,7 +112,12 @@ print STDERR " - release is: $releaseName (build $releaseId)\n - eval is: $evalI
|
|||
|
||||
if ($bucketChannels) {
|
||||
# Guard against the channel going back in time.
|
||||
my $curRelease = $bucketChannels->get_key($channelName)->{'x-amz-website-redirect-location'} // "";
|
||||
my $curRelease = "";
|
||||
|
||||
if (defined(my $object = $bucketChannels->get_key($channelName))) {
|
||||
$curRelease = $object->{'x-amz-website-redirect-location'} // "";
|
||||
}
|
||||
|
||||
if (!defined $ENV{'FORCE'}) {
|
||||
print STDERR "previous release is $curRelease\n";
|
||||
$! = 0; # Clear errno to avoid reporting non-fork/exec-related issues
|
||||
|
|
Loading…
Reference in a new issue