diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2022-03-26 02:53:34 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-26 02:53:34 +0100 |
commit | cefa526c6d3a45df2d0fcb7643ced828e2e87dea (patch) | |
tree | e3d19aa7d0881ae59d25692fb0c16b781c691b40 /app/serializers/rest/status_serializer.rb | |
parent | 2dd30804b62f750c2780b7043318cbe00d137429 (diff) |
Refactor formatter (#17828)
* Refactor formatter * Move custom emoji pre-rendering logic to view helpers * Move more methods out of Formatter * Fix code style issues * Remove Formatter * Add inline poll options to RSS feeds * Remove unused helper method * Fix code style issues * Various fixes and improvements * Fix test
Diffstat (limited to 'app/serializers/rest/status_serializer.rb')
-rw-r--r-- | app/serializers/rest/status_serializer.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/serializers/rest/status_serializer.rb b/app/serializers/rest/status_serializer.rb index 7c3dd673e..32c4e405e 100644 --- a/app/serializers/rest/status_serializer.rb +++ b/app/serializers/rest/status_serializer.rb @@ -1,6 +1,8 @@ # frozen_string_literal: true class REST::StatusSerializer < ActiveModel::Serializer + include FormattingHelper + attributes :id, :created_at, :in_reply_to_id, :in_reply_to_account_id, :sensitive, :spoiler_text, :visibility, :language, :uri, :url, :replies_count, :reblogs_count, @@ -71,7 +73,7 @@ class REST::StatusSerializer < ActiveModel::Serializer end def content - Formatter.instance.format(object) + status_content_format(object) end def url |