]> gitweb.michael.orlitzky.com - mailshears.git/blob - lib/prune/plugins/agendav.rb
43b5c99e883cf4287438297308b43769345806aa
[mailshears.git] / lib / prune / plugins / agendav.rb
1 require 'pg'
2
3 require 'prune/prune_plugin'
4 require 'rm/plugins/agendav'
5
6 class AgendavPrune < AgendavRm
7
8 include PrunePlugin
9
10 def get_leftover_domains(db_domains)
11 # AgenDAV doesn't have a concept of domains. We could parse the
12 # usernames to see what domains are present, but the point is
13 # moot: all leftover users will be pruned anyway.
14 return []
15 end
16
17
18 def get_leftover_users(db_users)
19 # Get a list of all users who have logged in to AgenDAV.
20 ad_users = self.list_users()
21 return ad_users - db_users
22 end
23
24 end