Module: Caprese::Serializer::Links::ClassMethods
- Defined in:
- lib/caprese/serializer/concerns/links.rb
Instance Method Summary collapse
-
#caprese_default_url_options_host ⇒ Object
Fetches the host from Caprese.config.default_url_options or fails if it is not set.
Instance Method Details
#caprese_default_url_options_host ⇒ Object
Note:
default_url_options is used to render the host in links that are serialized in the response
Fetches the host from Caprese.config.default_url_options or fails if it is not set
30 31 32 33 34 |
# File 'lib/caprese/serializer/concerns/links.rb', line 30 def Caprese.config..fetch(:host) do fail 'Caprese requires that config.default_url_options[:host] be set when rendering links.' end end |