fix rounding errors for signature count
This commit is contained in:
parent
136a6458c8
commit
01fe92eda6
@ -601,7 +601,7 @@ const checkAndDisplayActions = async (adminYes, name, cardIdentifier) => {
|
||||
} else if ((minterAdmins) && (minterAdmins.length > 1) && isBlockPassed){
|
||||
const totalAdmins = minterAdmins.length
|
||||
const fortyPercent = totalAdmins * 0.40
|
||||
minAdminCount = Math.round(fortyPercent)
|
||||
minAdminCount = Math.ceil(fortyPercent)
|
||||
console.warn(`this is another check to ensure minterAdmin group has more than 1 admin. IF so we will calculate the 40% needed for GROUP_APPROVAL, that number is: ${minAdminCount}`)
|
||||
}
|
||||
const addressInfo = await getNameInfo(name)
|
||||
|
@ -1067,7 +1067,7 @@ const checkAndDisplayRemoveActions = async (adminYes, name, cardIdentifier, name
|
||||
} else if ((minterAdmins) && (minterAdmins.length > 1) && isBlockPassed){
|
||||
const totalAdmins = minterAdmins.length
|
||||
const fortyPercent = totalAdmins * 0.40
|
||||
minAdminCount = Math.round(fortyPercent)
|
||||
minAdminCount = Math.ceil(fortyPercent)
|
||||
console.warn(`this is another check to ensure minterAdmin group has more than 1 admin. IF so we will calculate the 40% needed for GROUP_APPROVAL, that number is: ${minAdminCount}`)
|
||||
}
|
||||
if (isBlockPassed && (userState.isMinterAdmin || userState.isAdmin)) {
|
||||
|
@ -1442,7 +1442,7 @@ const checkAndDisplayInviteButton = async (adminYes, creator, cardIdentifier) =>
|
||||
|
||||
let minAdminCount = 9
|
||||
if (isBlockPassed) {
|
||||
minAdminCount = Math.round(minterAdmins.length * 0.4)
|
||||
minAdminCount = Math.ceil(minterAdmins.length * 0.4)
|
||||
console.warn(`Using 40% => ${minAdminCount}`)
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user