Clean existing whitelist address

This commit is contained in:
Serkan Reis 2022-11-18 19:50:33 +03:00
parent 8033d36aa4
commit 572becd4fc

View File

@ -70,7 +70,12 @@ export const WhitelistDetails = ({ onChange }: WhitelistDetailsProps) => {
useEffect(() => { useEffect(() => {
const data: WhitelistDetailsDataProps = { const data: WhitelistDetailsDataProps = {
whitelistType: whitelistState, whitelistType: whitelistState,
contractAddress: whitelistAddressState.value, contractAddress: whitelistAddressState.value
.toLowerCase()
.replace(/,/g, '')
.replace(/"/g, '')
.replace(/'/g, '')
.replace(/ /g, ''),
members: whitelistArray, members: whitelistArray,
unitPrice: unitPriceState.value ? (Number(unitPriceState.value) * 1_000_000).toString() : '', unitPrice: unitPriceState.value ? (Number(unitPriceState.value) * 1_000_000).toString() : '',
startTime: startDate ? (startDate.getTime() * 1_000_000).toString() : '', startTime: startDate ? (startDate.getTime() * 1_000_000).toString() : '',