docbrown/app/lib
Jeremy Friesen b4f17ed7dc
Allowing UserQuery to filter on multiple roles (#17919)
I had looked at using `User.with_any_roles` but that creates one User
query per role passed.  Which is not ideal, given that we want to have
an ActiveRecord::Relation object on which we'd paginate.

This adjustment does it's best to mimic Forem's role structure and
adhear to how Rolify builds the underlying query.

An astute reader will notice that in these specs we use `role: "admin"`
and `roles: ["Admin"]`; the primary reason relates the user interface
being worked on in forem/forem#17884.  It is my understanding that the
`role` approach and `roles` approach will be separated by a feature
flag (we're rolling out the `roles` approach).

Related to
- forem/forem#17491
- forem/forem#17884
2022-06-15 08:50:03 -04:00
..
acts_as_taggable_on Remove Elasticsearch ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ (#13606) 2021-05-03 11:09:45 -04:00
constants Allowing UserQuery to filter on multiple roles (#17919) 2022-06-15 08:50:03 -04:00
honeycomb [deploy] Optimization:Throttle Noisy Honeycomb Events More (#10143) 2020-09-01 15:21:07 -05:00
middlewares Rename SiteConfig to Settings::General (#13573) 2021-05-21 14:45:37 +02:00
redcarpet/render Rename SiteConfig to Settings::General (#13573) 2021-05-21 14:45:37 +02:00
reverse_markdown/converters Spelling fixes to live code (#15670) 2021-12-06 12:11:25 +02:00
api_constraints.rb [15 min fix] Fix some autoloading deprecation warnings (#13793) 2021-05-20 18:10:25 +02:00
app_secrets.rb Routine Rubopcop lint fixes (#17844) 2022-06-07 10:17:16 -04:00
black_box.rb Remove references to article.spaminess_rating (#17235) 2022-04-15 11:43:48 -04:00
html_css_to_image.rb Rename SiteConfig to Settings::General (#13573) 2021-05-21 14:45:37 +02:00
menu.rb Removing yard doc generation warnings (#17090) 2022-04-04 15:03:22 -04:00
rails_env_constraint.rb Easier feature flag handling for Cypress (#16379) 2022-02-03 10:42:13 -05:00
release_phase_notifier.rb Routine Rubopcop lint fixes (#17844) 2022-06-07 10:17:16 -04:00
seeder.rb Cleaning Test Runs for End to End (E2E) Tests (#12143) 2021-01-29 13:34:01 +01:00
string_attribute_cleaner.rb Renaming method for clarity (#16791) 2022-03-07 12:55:56 -05:00
throttled_call.rb Spike: Add ThrottledCall utility class (#12779) 2021-03-01 08:51:04 +07:00
url.rb Removing yard doc generation warnings (#17090) 2022-04-04 15:03:22 -04:00