Module: Nesta::Plugin::RelatedByCategory::Helpers
- Defined in:
- lib/nesta-plugin-related-by-category/init.rb
Instance Method Summary collapse
Instance Method Details
#has_related_articles?(page) ⇒ Boolean
6 7 8 |
# File 'lib/nesta-plugin-related-by-category/init.rb', line 6 def (page) !(Nesta::Plugin::RelatedByCategory.articles_through_categories(page).empty?) end |
#related_by_category(page, number = 3) ⇒ Object
10 11 12 |
# File 'lib/nesta-plugin-related-by-category/init.rb', line 10 def (page, number=3) Nesta::Plugin::RelatedByCategory.for_page(page, number) end |