diff --git a/src/photo/actions.tsx b/src/photo/actions.tsx index d3a05776..a3c690e9 100644 --- a/src/photo/actions.tsx +++ b/src/photo/actions.tsx @@ -167,7 +167,8 @@ export async function syncCacheAction() { } export async function getPhotoItemsAction(query: string) { - const photos = await getPhotos({ title: query, limit: 10 }); + const photos = (await getPhotos({ title: query, limit: 10 })) + .filter(({ title }) => Boolean(title)); return photos.length > 0 ? [{ heading: 'Photos', @@ -175,7 +176,14 @@ export async function getPhotoItemsAction(query: string) { items: photos.map(photo => ({ accessory: , label: titleForPhoto(photo), - annotation: formatDate(photo.takenAt), + annotation: <> + + {formatDate(photo.takenAt)} + + + {formatDate(photo.takenAt, true)} + + , path: pathForPhoto(photo), })), }]