diff options
author | multiple creatures <dev@multiple-creature.party> | 2019-10-26 01:06:34 -0500 |
---|---|---|
committer | multiple creatures <dev@multiple-creature.party> | 2019-10-26 01:06:34 -0500 |
commit | 87e48598f2fd3e9cca05fa5e1a73dc084ee3f5b6 (patch) | |
tree | 85793f6471ace78b45095a3a71f8edaf87611197 /app | |
parent | c939664d086d94efcab0172f92ab9b47cb0f29f7 (diff) |
fix breaking typos
Diffstat (limited to 'app')
-rw-r--r-- | app/lib/formatter.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/lib/formatter.rb b/app/lib/formatter.rb index 2dc9329f6..c190e193c 100644 --- a/app/lib/formatter.rb +++ b/app/lib/formatter.rb @@ -188,7 +188,7 @@ class Formatter def format(status, **options) unless options[:skip_cache] - html = Rails.cache.fetch() + html = Rails.cache.fetch("formatted_status:#{status.id}") unless html.nil? html = encode_custom_emojis(html, status.emojis, options[:autoplay]) if options[:custom_emojify] return html.html_safe # rubocop:disable Rails/OutputSafety @@ -305,7 +305,7 @@ class Formatter unless options[:skip_cache] html = Rails.cache.fetch("formatted_account:#{account.id}") unless html.nil? - html = encode_custom_emojis(html, account.emojis, options[:autoplay]) if account.local && options[:custom_emojify] + html = encode_custom_emojis(html, account.emojis, options[:autoplay]) if account.local? && options[:custom_emojify] return html.html_safe # rubocop:disable Rails/OutputSafety end end @@ -320,7 +320,7 @@ class Formatter Rails.cache.write("formatted_account:#{account.id}", html, expires_in: CACHE_TIME) - html = encode_custom_emojis(html, account.emojis, options[:autoplay]) if account.local && options[:custom_emojify] + html = encode_custom_emojis(html, account.emojis, options[:autoplay]) if account.local? && options[:custom_emojify] html.html_safe # rubocop:disable Rails/OutputSafety end |