From 6e36963645e6fced03870e732103b333eba4609e Mon Sep 17 00:00:00 2001 From: brrusselburg <25828824+brrusselburg@users.noreply.github.com> Date: Wed, 9 Apr 2025 15:13:50 -0500 Subject: [PATCH 1/2] Puts updates behind hidden setting --- lib/assigner.rb | 2 +- spec/system/assign_post_spec.rb | 4 ++-- spec/system/assign_topic_spec.rb | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/assigner.rb b/lib/assigner.rb index 4108dc06..71c05d8f 100644 --- a/lib/assigner.rb +++ b/lib/assigner.rb @@ -492,7 +492,7 @@ def queue_notification(assignment) end def small_action_username_or_name(assign_to) - if (assign_to.is_a?(User) && !SiteSetting.prioritize_username_in_ux) || + if (assign_to.is_a?(User) && SiteSetting.prioritize_full_name_in_ux) || !assign_to.try(:username) custom_fields = { "action_code_who" => assign_to.name || assign_to.username } else diff --git a/spec/system/assign_post_spec.rb b/spec/system/assign_post_spec.rb index 7ad73d82..4c170868 100644 --- a/spec/system/assign_post_spec.rb +++ b/spec/system/assign_post_spec.rb @@ -12,7 +12,7 @@ before do skip "Tests are broken and need to be fixed. See https://github.com/discourse/discourse/actions/runs/13890376408/job/38861216842" SiteSetting.assign_enabled = true - SiteSetting.prioritize_username_in_ux = true + SiteSetting.prioritize_username_in_ux = false # The system tests in this file are flaky and auth token related so turning this on SiteSetting.verbose_auth_token_logging = true @@ -61,7 +61,7 @@ def assign_post(post, assignee) end context "when prioritize_full_name_in_ux setting is enabled" do - before { SiteSetting.prioritize_username_in_ux = false } + before { SiteSetting.prioritize_full_name_in_ux = true } it "shows the user's name after assign" do visit "/t/#{topic.id}" diff --git a/spec/system/assign_topic_spec.rb b/spec/system/assign_topic_spec.rb index a374bdc3..20dc3e5a 100644 --- a/spec/system/assign_topic_spec.rb +++ b/spec/system/assign_topic_spec.rb @@ -50,7 +50,7 @@ end context "when prioritize_full_name_in_ux setting is enabled" do - before { SiteSetting.prioritize_username_in_ux = false } + before { SiteSetting.prioritize_full_name_in_ux = true } it "shows the user's name after assign" do visit "/t/#{topic.id}" From 0356ceba7a3b58bbda9513bd88111d8b39ed5cdd Mon Sep 17 00:00:00 2001 From: brrusselburg <25828824+brrusselburg@users.noreply.github.com> Date: Thu, 10 Apr 2025 12:05:33 -0500 Subject: [PATCH 2/2] tweak --- spec/system/assign_post_spec.rb | 1 - 1 file changed, 1 deletion(-) diff --git a/spec/system/assign_post_spec.rb b/spec/system/assign_post_spec.rb index 4c170868..ee2c78e0 100644 --- a/spec/system/assign_post_spec.rb +++ b/spec/system/assign_post_spec.rb @@ -12,7 +12,6 @@ before do skip "Tests are broken and need to be fixed. See https://github.com/discourse/discourse/actions/runs/13890376408/job/38861216842" SiteSetting.assign_enabled = true - SiteSetting.prioritize_username_in_ux = false # The system tests in this file are flaky and auth token related so turning this on SiteSetting.verbose_auth_token_logging = true