Class: Apill::Matchers::Subdomain
- Inherits:
-
Object
- Object
- Apill::Matchers::Subdomain
- Defined in:
- lib/apill/matchers/subdomain.rb
Instance Method Summary collapse
-
#initialize(allowed_subdomains: Apill.configuration.allowed_subdomains, allowed_api_subdomains: Apill.configuration.allowed_api_subdomains) ⇒ Subdomain
constructor
A new instance of Subdomain.
- #matches?(request) ⇒ Boolean
- #matches_api_subdomain?(request) ⇒ Boolean
Constructor Details
#initialize(allowed_subdomains: Apill.configuration.allowed_subdomains, allowed_api_subdomains: Apill.configuration.allowed_api_subdomains) ⇒ Subdomain
Returns a new instance of Subdomain.
4 5 6 7 8 9 |
# File 'lib/apill/matchers/subdomain.rb', line 4 def initialize(allowed_subdomains: Apill.configuration.allowed_subdomains, allowed_api_subdomains: Apill.configuration.allowed_api_subdomains) self.allowed_subdomains = Array(allowed_subdomains) self.allowed_api_subdomains = Array(allowed_api_subdomains) end |