You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
mastodon/app/controllers
Akihiko Odaki 64ef37b89d
Introduce ApplicationController#cache_collection_paginated_by_id (#14677)
* Replace incorrect use of distinct with group

Some uses of ActiveRecord::QueryMethods#distinct pass field names but they
are incorrect for the current version of Rails.

ActiveRecord::QueryMethods#group provides the expected behavior and
benefits performance. See commit 6da24aad4c.

* Introduce ApplicationController#cache_collection_paginated_by_id

ApplicationController#cache_collection_paginated_by_id fuses
ApplicationController#cache_collection and Paginable.paginate_by_id.

An advantage of this method is that it prevents from modifying scope which
Paginable.paginate_by_id may provide.
ApplicationController#cache_collection always return an array and there
is no possibility of the scope modification. It is also clear for a
programmer, considering the implication of "cache".

This method can also emit more efficient queries by using
Cacheable.cache_ids before calling Paginable.paginate_by_id.
6 years ago
..
activitypub Introduce ApplicationController#cache_collection_paginated_by_id (#14677) 6 years ago
admin Improve email address validation (#14565) 6 years ago
api Introduce ApplicationController#cache_collection_paginated_by_id (#14677) 6 years ago
auth Add WebAuthn as an alternative 2FA method (#14466) 6 years ago
concerns Introduce ApplicationController#cache_collection_paginated_by_id (#14677) 6 years ago
oauth Fix settings pages being cacheable by the browser (#12714) 6 years ago
settings Add WebAuthn as an alternative 2FA method (#14466) 6 years ago
well_known Fix webfinger returning wrong status code on malformed or missing param (#13759) 6 years ago
about_controller.rb Add table of contents to about page (#11885) 7 years ago
account_follow_controller.rb Add specific rate limits for posting and following (#13172) 6 years ago
account_unfollow_controller.rb
accounts_controller.rb Introduce ApplicationController#cache_collection_paginated_by_id (#14677) 6 years ago
application_controller.rb Fix RSS feeds not being cachable (#14368) 6 years ago
authorize_interactions_controller.rb Add specific rate limits for posting and following (#13172) 6 years ago
custom_css_controller.rb Fix redirecting non-functional accounts on public pages (#11978) 7 years ago
directories_controller.rb Fix functional user requirements in whitelist mode (#14093) 6 years ago
emojis_controller.rb
filters_controller.rb Fix missing authentication call in filters controller (#12746) 6 years ago
follower_accounts_controller.rb Fix functional user requirements in whitelist mode (#14093) 6 years ago
following_accounts_controller.rb Fix functional user requirements in whitelist mode (#14093) 6 years ago
home_controller.rb Fix other sessions not being logged out on password change (#14252) 6 years ago
instance_actors_controller.rb
intents_controller.rb
invites_controller.rb
manifests_controller.rb Fix redirecting non-functional accounts on public pages (#11978) 7 years ago
media_controller.rb Fix functional user requirements in whitelist mode (#14093) 6 years ago
media_proxy_controller.rb Fix media attachments enumeration (#14254) 6 years ago
public_timelines_controller.rb
relationships_controller.rb Change followers page to relationships page in admin UI (#12927) 6 years ago
remote_follow_controller.rb Fix redirecting non-functional accounts on public pages (#11978) 7 years ago
remote_interaction_controller.rb Fix functional user requirements in whitelist mode (#14093) 6 years ago
shares_controller.rb
statuses_controller.rb Fix functional user requirements in whitelist mode (#14093) 6 years ago
tags_controller.rb Fix rubocop warning (#14288) 6 years ago