Skip to content

Commit

Permalink
avoid multiple fetches of non working days
Browse files Browse the repository at this point in the history
  • Loading branch information
ulferts authored and oliverguenther committed Sep 22, 2022
1 parent 288a147 commit 423d339
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/services/work_packages/shared/working_days.rb
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ def working_week_days
end

def non_working_dates
@non_working_dates ||= Set.new(NonWorkingDay.pluck(:date))
@non_working_dates ||= RequestStore.fetch(:work_package_non_working_dates) { Set.new(NonWorkingDay.pluck(:date)) }
end
end
end
Expand Down

0 comments on commit 423d339

Please sign in to comment.