aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org>2018-12-12 17:49:40 +0200
committerSergey Poznyakoff <gray@gnu.org>2018-12-12 17:50:54 +0200
commit895970cc2eab50c2f262582a83ec93f3a4d9ea5c (patch)
tree280d132831d181cac276fbb1014f80f1ff9a0ce1 /lib
parent0e3d9069c66874fc729d95cacaeca2a1375d5d41 (diff)
downloadglacier-895970cc2eab50c2f262582a83ec93f3a4d9ea5c.tar.gz
glacier-895970cc2eab50c2f262582a83ec93f3a4d9ea5c.tar.bz2
Minor fix
* lib/App/Glacier/Command/Periodic.pm (run): Use the touchdir method.
Diffstat (limited to 'lib')
-rw-r--r--lib/App/Glacier/Command/Periodic.pm17
1 files changed, 1 insertions, 16 deletions
diff --git a/lib/App/Glacier/Command/Periodic.pm b/lib/App/Glacier/Command/Periodic.pm
index 85f3cc0..638639a 100644
--- a/lib/App/Glacier/Command/Periodic.pm
+++ b/lib/App/Glacier/Command/Periodic.pm
@@ -6,8 +6,6 @@ use parent qw(App::Glacier::Command);
use Carp;
use Data::Dumper;
use File::Basename;
-use File::Path qw(make_path);
-use App::Glacier::Timestamp;
=head1 NAME
@@ -73,20 +71,7 @@ sub run {
$key, $res);
my $localname = $self->archive_cache_filename($vault,
$res->{ArchiveId});
- my $dir = dirname($localname);
- unless (-d $dir) {
- make_path($dir, { error => \my $err });
- if (@$err) {
- for my $diag (@$err) {
- my ($dir, $message) = %$diag;
- if ($dir eq '') {
- $self->error($message);
- } else {
- $self->error("can't create directory $dir: $message");
- }
- }
- }
- }
+ $self->touchdir(dirname($localname));
require App::Glacier::Command::Get;
my $get = clone App::Glacier::Command::Get($self);

Return to:

Send suggestions and report system problems to the System administrator.