Skip to content

Commit

Permalink
roster: Check if player already selected to pay
Browse files Browse the repository at this point in the history
  • Loading branch information
Joe2k committed Sep 15, 2024
1 parent fc9ca8b commit 6fcb74e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions frontend/src/components/roster/AddToRoster.js
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,9 @@ const AddPlayerRegistrationForm = componentProps => {
when={
!(componentProps.roster || [])
.map(reg => reg.player.id)
.includes(props.getValue()) &&
!selectedPlayers()
.map(p => p.id)
.includes(props.getValue())
}
fallback={<span>Added</span>}
Expand Down

0 comments on commit 6fcb74e

Please sign in to comment.