From: Go MAEDA Date: Fri, 5 May 2023 03:49:12 +0000 (+0000) Subject: Display order of watchers in the sidebar is indeterminate (#38458). X-Git-Tag: 5.1.0~141 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=53ec1c0e43c8b33fbe923805893ac1021c9f4766;p=redmine.git Display order of watchers in the sidebar is indeterminate (#38458). Patch by Holger Just. git-svn-id: https://svn.redmine.org/redmine/trunk@22224 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/helpers/watchers_helper.rb b/app/helpers/watchers_helper.rb index dfd3d5c49..d8a1e0775 100644 --- a/app/helpers/watchers_helper.rb +++ b/app/helpers/watchers_helper.rb @@ -48,7 +48,7 @@ module WatchersHelper def watchers_list(object) remove_allowed = User.current.allowed_to?("delete_#{object.class.name.underscore}_watchers".to_sym, object.project) content = ''.html_safe - lis = object.watcher_users.collect do |user| + lis = object.watcher_users.sorted.collect do |user| s = ''.html_safe s << avatar(user, :size => "16").to_s s << link_to_principal(user, class: user.class.to_s.downcase)