Skip to content

Commit

Permalink
🧹 Don't specify the id now that we have a relationship defined
Browse files Browse the repository at this point in the history
  • Loading branch information
zspencer committed Jan 30, 2024
1 parent a8a7ce6 commit 84e4f9c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/furniture/tobias/payout.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def issue

per_beneficiary_amount = (amount / beneficiaries.count)
beneficiaries.each do |beneficiary|
payments.create_with(amount: per_beneficiary_amount).find_or_create_by(beneficiary_id: beneficiary.id)
payments.create_with(amount: per_beneficiary_amount).find_or_create_by(beneficiary: beneficiary)
end
end
end
Expand Down

0 comments on commit 84e4f9c

Please sign in to comment.