Hi, I would like to let you know get_location_constraint has an issue.
Reproduce
#!/usr/bin/perl
use strict;
use warnings;
use Amazon::S3;
my $s3 = Amazon::S3->new({
aws_access_key_id => 'YOUR ACCESS KEY',
aws_secret_access_key => 'YOUR SECRET',
region => 'us-east-1',
});
my $bucket = $s3->bucket({ bucket => 'YOUR BUCKET' });
print "------------------------\n";
my $loc = $bucket->get_location_constraint();
print "$loc\n";
print "------------------------\n";
Fill in YOUR ACCESS KEY, YOUR SECRET and YOUR BUCKET for yours, and run above script, then the following error occurred.
Actual
$ perl -I local/lib/perl5 getlocation_error.pl
------------------------
Can't use string ("us-east-1") as a HASH ref while "strict refs" in use at local/lib/perl5/Amazon/S3/Bucket.pm line 1080.
Hi, I would like to let you know get_location_constraint has an issue.
Reproduce
Fill in YOUR ACCESS KEY, YOUR SECRET and YOUR BUCKET for yours, and run above script, then the following error occurred.
Actual
Expected
Suggestion
https://github.com/rlauer6/perl-amazon-s3/blob/8bd099e8b408bd7231d426395dd65a3604e28bc0/src/main/perl/lib/Amazon/S3/Bucket.pm.in#L1080
$_xpc
is already parsed in_send_request
by_xpc_of_content
. The line should be below.Thanks in advance!