media: fix setting description

This commit is contained in:
Alex Gleason 2024-09-07 10:32:14 -05:00
parent 8efd6fbb20
commit 99a25e1e18
No known key found for this signature in database
GPG key ID: 7211D1F99744FBB7
2 changed files with 1 additions and 2 deletions

View file

@ -5,7 +5,6 @@ import { Time } from '@/utils/time.ts';
export interface DittoUpload { export interface DittoUpload {
id: string; id: string;
pubkey: string; pubkey: string;
description?: string;
url: string; url: string;
tags: string[][]; tags: string[][];
uploadedAt: Date; uploadedAt: Date;

View file

@ -54,7 +54,7 @@ const updateMediaController: AppController = async (c) => {
dittoUploads.set(id, { dittoUploads.set(id, {
...upload, ...upload,
description, tags: upload.tags.filter(([name]) => name !== 'alt').concat([['alt', description]]),
}); });
return c.json({ message: 'ok' }, 200); return c.json({ message: 'ok' }, 200);