Skip to content

Commit

Permalink
bugfix for friends
Browse files Browse the repository at this point in the history
  • Loading branch information
kinoppyd committed May 13, 2024
1 parent 0d34700 commit 7dca512
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions app/controllers/plans_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,11 @@ def set_attributes_for_turbo_stream
params[:remove_schedule_id] ||
params.dig(:plan, :remove_schedule_id)


@friends_schedules_map = @user.profile.friend_profiles.to_h do |profile|
[profile.id, profile.user.plans.find_by(event: @event)&.plan_schedules&.map(&:schedule_id) || []]
end

@row, @track_list = catch(:abort) do
@schedule_table.days.each do |day|
@table = @schedule_table[day]
Expand Down

0 comments on commit 7dca512

Please sign in to comment.