]> git.openstreetmap.org Git - rails.git/blobdiff - script/update-spam-blocks
Block any address with more than one suspended user
[rails.git] / script / update-spam-blocks
index 903fc9b8a35a61d0b07f72779434eeea61597521..8476fcb9dd75a2e4f9a4d2866c5ed6c8fa7415bb 100755 (executable)
@@ -12,10 +12,9 @@ addresses = User.count(
 )
 
 addresses.each do |address,count|
-  if count > 2
+  if count > 1
     acl = Acl.find(:first, :conditions => {
       :address => address,
-      :netmask => "255.255.255.255"
     })
 
     unless acl
@@ -32,7 +31,6 @@ addresses.each do |address,count|
 end
 
 acls = Acl.find(:all, :conditions => {
-  :netmask => "255.255.255.255",
   :k => "no_account_creation",
   :v => "auto_spam_block"
 })