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
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
memoize instead of just assigning instance variables
Ivan Kuchin048906a001ad
diff --git a/app/menus/projects/menu.rb b/app/menus/projects/menu.rbindex 9a8b1825dfe..e7cc468af97 100644--- a/app/menus/projects/menu.rb+++ b/app/menus/projects/menu.rb@@ -120,14 +120,14 @@ module Projectsenddef persisted_filters- @persisted_filters = ::ProjectQuery+ @persisted_filters ||= ::ProjectQuery.visible(current_user).with_favored_by_user(current_user).order(favored: :desc, name: :asc)enddef favored_ids- @favored_ids = persisted_filters.select(&:favored).to_set(&:id)+ @favored_ids ||= persisted_filters.select(&:favored).to_set(&:id)enddef modification_params?