lib/imap/backup/configuration/store.rb in imap-backup-1.0.11 vs lib/imap/backup/configuration/store.rb in imap-backup-1.0.12

- old
+ new

@@ -31,20 +31,28 @@ Utils.check_permissions path, 0700 end mkdir_private path File.open(pathname, 'w') { |f| f.write(JSON.pretty_generate(data)) } FileUtils.chmod 0600, pathname - @data[:accounts].each do |account| + accounts.each do |account| mkdir_private account[:local_path] account[:folders].each do |f| parts = f[:name].split('/') p = account[:local_path].clone parts.each do |part| p = File.join(p, part) mkdir_private p end end end + end + + def accounts + data[:accounts] + end + + def debug? + data.include?(:debug) end private def data