This commit is contained in:
syuilo 2025-09-24 10:33:14 +09:00
parent ee5b9ba1a9
commit 182d147156
2 changed files with 4 additions and 0 deletions

View File

@ -183,6 +183,7 @@ export const paramDef = {
},
required: ['choices'],
},
scheduledAt: { type: 'integer', nullable: true },
},
required: [],
} as const;
@ -212,6 +213,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
visibility: ps.visibility,
visibleUserIds: ps.visibleUserIds ?? [],
channelId: ps.channelId ?? undefined,
scheduledAt: ps.scheduledAt ? new Date(ps.scheduledAt) : null,
}).catch((err) => {
if (err instanceof IdentifiableError) {
switch (err.id) {

View File

@ -215,6 +215,7 @@ export const paramDef = {
},
required: ['choices'],
},
scheduledAt: { type: 'integer', nullable: true },
},
required: ['draftId'],
} as const;
@ -244,6 +245,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
visibility: ps.visibility,
visibleUserIds: ps.visibleUserIds ?? [],
channelId: ps.channelId ?? undefined,
scheduledAt: ps.scheduledAt ? new Date(ps.scheduledAt) : null,
}).catch((err) => {
if (err instanceof IdentifiableError) {
switch (err.id) {