Removed 'automatic' resolution

This commit is contained in:
Milli 2022-05-25 17:38:56 +02:00
parent 944de9398a
commit 9b6e551bad
4 changed files with 5 additions and 15 deletions

View File

@ -28,7 +28,7 @@ export type FullContract<
isResolved: boolean
resolutionTime?: number // When the contract creator resolved the market
resolution?: string
resolutionType: 'manual' | 'combined' | 'automatic'
resolutionType: 'manual' | 'combined'
closeEmailsSent?: number
@ -98,9 +98,9 @@ export type Numeric = {
}
export type outcomeType = 'BINARY' | 'MULTI' | 'FREE_RESPONSE' | 'NUMERIC'
export type resolutionType = 'MANUAL' | 'COMBINED' | 'AUTOMATIC'
export type resolutionType = 'MANUAL' | 'COMBINED'
export const OUTCOME_TYPES = ['BINARY', 'MULTI', 'FREE_RESPONSE', 'NUMERIC']
export const RESOLUTION_TYPES = ['MANUAL', 'COMBINED', 'AUTOMATIC']
export const RESOLUTION_TYPES = ['MANUAL', 'COMBINED']
export const MAX_QUESTION_LENGTH = 480
export const MAX_DESCRIPTION_LENGTH = 10000

View File

@ -64,6 +64,7 @@ export function getNewContract(
isResolved: false,
createdTime: Date.now(),
closeTime,
resolutionType: 'manual',
volume: 0,
volume24Hours: 0,

View File

@ -142,11 +142,11 @@ export const createContract = newEndpoint(['POST'], async (req, _res) => {
ante,
closeTime,
tags ?? [],
resolutionType,
NUMERIC_BUCKET_COUNT,
min ?? 0,
max ?? 0,
manaLimitPerUser ?? 0,
resolutionType,
)
if (!isFree && ante) await chargeUser(creator.id, ante, true)

View File

@ -396,17 +396,6 @@ export function NewContract(props: { question: string; tag?: string }) {
/>
<span className="label-text">Combined (experimental)</span>
</label>
<label className="label cursor-pointer gap-2">
<input
className="radio"
type="radio"
name="res"
checked={resolutionType === 'AUTOMATIC'}
value="AUTOMATIC"
onChange={() => setResolutionType('AUTOMATIC')}
/>
<span className="label-text">Automatic (experimental)</span>
</label>
</Row>
<Spacer h={4} />