Sha256: 006971e1dd72fe61df8cd40564eb13a7ae4b2cbb59b795cc663f76709539188d
Contents?: true
Size: 530 Bytes
Versions: 12
Compression:
Stored size: 530 Bytes
Contents
module Gluttonberg module Content require 'despamilator/filter' module DespamilatorFilter class IPAddressURL < Despamilator::Filter def name 'IP Address URL' end def description 'Detects IP address URLs' end def parse subject subject.register_match!({ :score => 0.5, :filter => self }) if subject.text.downcase.count(/http:\/\/\d+\.\d+\.\d+\.\d+/) > 0 end end end end #Content end #Gluttonberg
Version data entries
12 entries across 12 versions & 1 rubygems