Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Reverse order of added shares to match the order in the autocompleter

Henriette Dargee6221d699662
diff --git a/app/controllers/work_packages/shares_controller.rb b/app/controllers/work_packages/shares_controller.rb
index deee313af45..05b7a6cca9c 100644
--- a/app/controllers/work_packages/shares_controller.rb
+++ b/app/controllers/work_packages/shares_controller.rb
@@ -58,11 +58,11 @@ class WorkPackages::SharesController < ApplicationController
end
end
- @shares = overall_result.map(&:result)
+ @shares = overall_result.map(&:result).reverse
unless overall_result.nil?
if current_visible_member_count > 1
- respond_with_prepend_share
+ respond_with_prepend_shares
else
respond_with_replace_modal
end
@@ -99,7 +99,7 @@ class WorkPackages::SharesController < ApplicationController
respond_with_turbo_streams
end
- def respond_with_prepend_share
+ def respond_with_prepend_shares
replace_via_turbo_stream(
component: WorkPackages::Share::InviteUserFormComponent.new(work_package: @work_package)
)