Class: Recoil::Email

Inherits:
Struct
  • Object
show all
Defined in:
lib/recoil/email.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#bouncesObject

Returns the value of attribute bounces

Returns:

  • (Object)

    the current value of bounces



2
3
4
# File 'lib/recoil/email.rb', line 2

def bounces
  @bounces
end

Class Method Details

.blacklisted?(email) ⇒ Boolean

Returns:

  • (Boolean)


3
4
5
# File 'lib/recoil/email.rb', line 3

def self.blacklisted?(email)
  new(Bounce.where(email: email).count).blacklisted?
end

Instance Method Details

#blacklisted?Boolean

Returns:

  • (Boolean)


7
8
9
# File 'lib/recoil/email.rb', line 7

def blacklisted?
  Recoil.blacklist_threshold.call(self)
end