~cytrogen/masto-fe

ref: fd284311e79854d6bc2901a9d9363ba9e7e00513 masto-fe/app/controllers/api/v1/custom_emojis_controller.rb -rw-r--r-- 362 bytes
fd284311 — Christian Schmidt Do not normalize URL before fetching it (#26219) 2 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
# frozen_string_literal: true

class Api::V1::CustomEmojisController < Api::BaseController
  vary_by '', unless: :disallow_unauthenticated_api_access?

  def index
    cache_even_if_authenticated! unless disallow_unauthenticated_api_access?
    render_with_cache(each_serializer: REST::CustomEmojiSerializer) { CustomEmoji.listed.includes(:category) }
  end
end