Small optimizations in Atom feeds
This commit is contained in:
parent
19a259915e
commit
7e00a21ea6
5 changed files with 6 additions and 4 deletions
|
@ -46,7 +46,7 @@ class Status < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def title
|
||||
content.truncate(80, omission: "...")
|
||||
content
|
||||
end
|
||||
|
||||
def reblogs_count
|
||||
|
|
|
@ -4,6 +4,8 @@ class StreamEntry < ActiveRecord::Base
|
|||
|
||||
validates :account, :activity, presence: true
|
||||
|
||||
scope :with_includes, -> { includes(:activity) }
|
||||
|
||||
def object_type
|
||||
orphaned? ? :activity : (targeted? ? :activity : self.activity.object_type)
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue