]>
gitweb.michael.orlitzky.com - mailshears.git/blob - dovecot_mailstore.rb
eddd822f0bfff4c04fbf2d9bcf2da51aba17d23f
1 require 'common/dovecot_mailstore_plugin'
2 require 'prune/prune_plugin'
3 require 'rm/plugins/dovecot_mailstore'
5 class DovecotMailstorePrune
< DovecotMailstoreRm
7 include DovecotMailstorePlugin
11 def get_leftover_domains(db_domains
)
12 # Get the list of domains according to the filesystem.
13 fs_domains
= self.list_domains()
15 # Return the list of domains on the filesystem that aren't in the DB.
16 return (fs_domains
- db_domains
)
19 def get_leftover_accounts(db_accounts
)
20 # Get the list of accounts according to the filesystem.
21 fs_domains
= self.list_domains()
22 fs_accounts
= self.list_domains_users(fs_domains
)
24 # And return the accounts on the filesystem that aren't in the DB.
25 return (fs_accounts
- db_accounts
)