From 8e8459fa559865428963b08e6422fba9617240f5 Mon Sep 17 00:00:00 2001 From: syuilo Date: Sun, 15 Nov 2020 12:34:47 +0900 Subject: wip: clip --- src/models/repositories/clip.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/models') diff --git a/src/models/repositories/clip.ts b/src/models/repositories/clip.ts index 7cc3fb7110..f5c70a1829 100644 --- a/src/models/repositories/clip.ts +++ b/src/models/repositories/clip.ts @@ -15,8 +15,10 @@ export class ClipRepository extends Repository { return { id: clip.id, createdAt: clip.createdAt.toISOString(), + userId: clip.userId, name: clip.name, description: clip.description, + isPublic: clip.isPublic, }; } } @@ -38,6 +40,11 @@ export const packedClipSchema = { format: 'date-time', description: 'The date that the Clip was created.' }, + userId: { + type: 'string' as const, + optional: false as const, nullable: false as const, + format: 'id', + }, name: { type: 'string' as const, optional: false as const, nullable: false as const, @@ -48,5 +55,10 @@ export const packedClipSchema = { optional: false as const, nullable: true as const, description: 'The description of the Clip.' }, + isPublic: { + type: 'boolean' as const, + optional: false as const, nullable: false as const, + description: 'Whether this Clip is public.', + }, }, }; -- cgit v1.2.3-freya