diff options
author | multiple creatures <dev@multiple-creature.party> | 2019-12-10 05:33:44 -0600 |
---|---|---|
committer | multiple creatures <dev@multiple-creature.party> | 2019-12-10 05:33:44 -0600 |
commit | 302f532440d0bfad1784d9b696e099af9d5a3246 (patch) | |
tree | 8362cddc2012e185e6a9c446441b7128c63f65d0 /app/helpers/text_helper.rb | |
parent | 2da941beaab17923ec72af0c2e2d8de6c62cd20e (diff) |
fix newlines in normalized text + make `tag` & `tags` headings mean the same thing
Diffstat (limited to 'app/helpers/text_helper.rb')
-rw-r--r-- | app/helpers/text_helper.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/helpers/text_helper.rb b/app/helpers/text_helper.rb index ac49e56f0..50a7c248a 100644 --- a/app/helpers/text_helper.rb +++ b/app/helpers/text_helper.rb @@ -29,12 +29,12 @@ module TextHelper end def normalize_status(status) - "#{_format_tags(status)}\n#{_format_spoiler(status)}\n#{_format_status(status)}\n#{_format_desc(status)}".delete("\n\n").strip + "#{_format_tags(status)}\n#{_format_spoiler(status)}\n#{_format_status(status)}\n#{_format_desc(status)}".strip end def _format_tags(status) return unless status.tags.present? - "tags #{status.tags.pluck(:name).join("\ntags ")}" + "tag #{status.tags.pluck(:name).join("\ntag ")}" end def _format_spoiler(status) |