Module: Roda::RodaPlugins::HashPublic::InstanceMethods
- Defined in:
- lib/roda/plugins/hash_public.rb
Instance Method Summary collapse
-
#hash_path(file) ⇒ Object
Return a path to the static file that could be served by r.hash_public.
Instance Method Details
#hash_path(file) ⇒ Object
Return a path to the static file that could be served by r.hash_public. This does not check the file is inside the directory for performance reasons, so this should not be called with untrusted input.
104 105 106 |
# File 'lib/roda/plugins/hash_public.rb', line 104 def hash_path(file) "/#{opts[:hash_public_prefix]}/#{self.class.hash_path_digest(file)}/#{file}" end |