Class: Rack::ContentSecurityPolicy::RackResponse

Inherits:
Object
  • Object
show all
Defined in:
lib/rack/content_security_policy/contracts.rb

Class Method Summary collapse

Class Method Details

.to_sObject



41
42
43
# File 'lib/rack/content_security_policy/contracts.rb', line 41

def self.to_s
  'A Rack response'
end

.valid?(val) ⇒ Boolean

Returns:

  • (Boolean)


37
38
39
# File 'lib/rack/content_security_policy/contracts.rb', line 37

def self.valid?(val)
  Contract.valid?(val, [Contracts::Int, Hash, Contracts::RespondTo[:each]])
end