Allow M$ limit for markets

This commit is contained in:
Ian Philips 2022-05-06 16:10:42 -04:00
parent 466ffdf921
commit a4216929f6
3 changed files with 6 additions and 1 deletions

View File

@ -161,6 +161,7 @@ export function getContractBetMetrics(contract: Contract, yourBets: Bet[]) {
return { return {
invested: Math.max(0, currentInvested), invested: Math.max(0, currentInvested),
currentInvested,
payout, payout,
netPayout, netPayout,
profit, profit,

View File

@ -31,6 +31,8 @@ export type FullContract<
closeEmailsSent?: number closeEmailsSent?: number
manaLimitPerUser?: number
volume: number volume: number
volume24Hours: number volume24Hours: number
volume7Days: number volume7Days: number

View File

@ -22,7 +22,8 @@ export function getNewContract(
initialProb: number, initialProb: number,
ante: number, ante: number,
closeTime: number, closeTime: number,
extraTags: string[] extraTags: string[],
manaLimitPerUser: number
) { ) {
const tags = parseTags( const tags = parseTags(
`${question} ${description} ${extraTags.map((tag) => `#${tag}`).join(' ')}` `${question} ${description} ${extraTags.map((tag) => `#${tag}`).join(' ')}`
@ -64,6 +65,7 @@ export function getNewContract(
liquidityFee: 0, liquidityFee: 0,
platformFee: 0, platformFee: 0,
}, },
manaLimitPerUser,
}) })
return contract as Contract return contract as Contract