Skip to content

A platform for community discussion. Free, open, simple.

DEV: Add comment about `UserController#cards` route (#16882)

David Taylora8163a5c0cde
diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb
index 20e90ae126e..67f78b1bbba 100644
--- a/app/controllers/users_controller.rb
+++ b/app/controllers/users_controller.rb
@@ -105,6 +105,7 @@ class UsersController < ApplicationController
show(for_card: true)
end
+ # This route is not used in core, but is used by theme components (e.g. https://meta.discourse.org/t/144479)
def cards
return redirect_to path('/login') if SiteSetting.hide_user_profiles_from_public && !current_user