Skip to content

Commit

Permalink
[Teams] Fix team seat quantity type conversion
Browse files Browse the repository at this point in the history
  • Loading branch information
jankeromnes committed Apr 9, 2021
1 parent 540d387 commit df7c5e7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions components/dashboard/src/settings/Teams.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,7 @@ function AddMembersModal(props: {
<div className="flex flex-col space-y-2 pb-4">
<label htmlFor="quantity" className="font-medium">Members</label>
<select name="quantity" value={quantity} className="rounded-md w-full border-2 border-gray-400"
onChange={(e) => setQuantity(e.target.value as any)}>
onChange={(e) => setQuantity(parseInt(e.target.value || '1', 10))}>
{quantities.map(n => (
<option key={`quantity-${n}`} value={n}>{n}</option>
))}
Expand Down Expand Up @@ -684,7 +684,7 @@ function NewTeamModal(props: {
<div className="flex flex-col space-y-2">
<label htmlFor="quantity" className="font-medium">Members</label>
<select name="quantity" value={quantity} className="rounded-md w-full border-2 border-gray-400"
onChange={(e) => setQuantity(e.target.value as any)}>
onChange={(e) => setQuantity(parseInt(e.target.value || '1', 10))}>
{quantities.map(n => (
<option key={`quantity-${n}`} value={n}>{n}</option>
))}
Expand Down Expand Up @@ -902,4 +902,4 @@ function setLocalStorageObject(key: string, object: Object): void {
window.localStorage.setItem(key, JSON.stringify(object));
} catch {
}
}
}

0 comments on commit df7c5e7

Please sign in to comment.