]> gitweb.michael.orlitzky.com - mailshears.git/blobdiff - lib/rm/plugins/davical.rb
Add a TODO item.
[mailshears.git] / lib / rm / plugins / davical.rb
index ce5828a627b3cf72a29069815feab17660a07267..04d5fbf024dde17e47375afa486d4359c897c9dd 100644 (file)
@@ -12,15 +12,12 @@ class DavicalRm
   include RmPlugin
 
 
-  def delete_domain(domain)
-    # DAViCal doesn't have a concept of domains.
-  end
-
-
   def delete_account(account)
     # Delete the given username. DAViCal uses foreign keys properly
     # and only supports postgres, so we let the ON DELETE CASCADE
     # trigger handle most of the work.
+    raise NonexistentAccountError.new(account) if not user_exists(account)
+
     sql_queries = ['DELETE FROM usr WHERE username = $1']
 
     begin
@@ -46,14 +43,4 @@ class DavicalRm
   end
 
 
-
-  def get_domain_usernames(domain)
-    usernames = get_davical_usernames();
-    matches = usernames.select do |username|
-      username =~ /@#{domain}$/
-    end
-
-    return matches
-  end
-
 end