mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2025-12-24 20:26:24 +00:00
Fix sending previews without images
This commit is contained in:
@@ -78,7 +78,7 @@ export type CallbackResultType = {
|
||||
type PreviewType = {
|
||||
url: string;
|
||||
title: string;
|
||||
image: AttachmentType;
|
||||
image?: AttachmentType;
|
||||
};
|
||||
|
||||
type QuoteAttachmentType = {
|
||||
@@ -573,7 +573,9 @@ export default class MessageSender {
|
||||
const preview = await Promise.all(
|
||||
(message.preview || []).map(async (item: PreviewType) => ({
|
||||
...item,
|
||||
image: await this.makeAttachmentPointer(item.image),
|
||||
image: item.image
|
||||
? await this.makeAttachmentPointer(item.image)
|
||||
: undefined,
|
||||
}))
|
||||
);
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
|
||||
Reference in New Issue
Block a user