app/models/page.rb in tkh_content-0.1.9.3 vs app/models/page.rb in tkh_content-0.1.10
- old
+ new
@@ -33,10 +33,10 @@
scope :with_parent_id, lambda { |id| where('parent_id = ?', id) }
scope :by_title, order('title')
scope :by_menu_position, order('menu_position')
def nickname
- short_title || title
+ @nickname ||= short_title || title
end
### menu related instance methods
def orphan?