diff options
author | Matthew Bloch <mattbee@yoga.home.bloch.tv> | 2014-11-05 14:28:42 +0000 |
---|---|---|
committer | Matthew Bloch <mattbee@yoga.home.bloch.tv> | 2014-11-05 14:28:42 +0000 |
commit | ceb4dfa6003071c8dd5d21417bf26c2701ddb8d8 (patch) | |
tree | 26235c1bbf66e0df165d99a4ffa90de8e63c14f6 /byteback-snapshot | |
parent | c88333e19b459685f57ba3f246c3fdd684681542 (diff) |
A few more bug fixes from the last refactoring.
Diffstat (limited to 'byteback-snapshot')
-rwxr-xr-x | byteback-snapshot | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/byteback-snapshot b/byteback-snapshot index a14e0f8..0f0c9e9 100755 --- a/byteback-snapshot +++ b/byteback-snapshot @@ -27,10 +27,10 @@ fatal("--root not readable") unless File.directory?("#{@root}") @backups = BackupDirectory.new(@root) -last_snapshot_time = @backups.snapshot_times.last +last_snapshot_time = @backups.snapshots.last.time fatal("Last snapshot was less than six hours ago") unless !last_snapshot_time || - Time.now - @backups.snapshot_times.last >= 6*60*60 # FIXME: make configurable + Time.now - last_snapshot_time >= 6*60*60 # FIXME: make configurable info "Making new snapshot" @backups.new_snapshot! |