Module: SlugHelper
- Defined in:
- app/helpers/slug_helper.rb
Instance Method Summary collapse
Instance Method Details
#slug_path(content) ⇒ Object
3 4 5 6 7 8 9 |
# File 'app/helpers/slug_helper.rb', line 3 def slug_path(content) if content.respond_to?(:slug) slug_engine.permalink_path(content.slug) else polymorphic_path(content) end end |
#slug_url(content) ⇒ Object
11 12 13 14 15 16 17 |
# File 'app/helpers/slug_helper.rb', line 11 def slug_url(content) if content.respond_to?(:slug) slug_engine.permalink_url(content.slug) else polymorphic_url(content) end end |