@ -1093,7 +1093,7 @@ export class SessionConversation extends React.Component<Props, State> {
error && error.stack ? error.stack : error
);
ToastUtils.pushLoadAttachmentFailure();
ToastUtils.pushLoadAttachmentFailure(error?.message);
return;
}
@ -12,7 +12,7 @@ export async function downloadAttachment(attachment: any) {
serverUrl
let res: ArrayBuffer | null = null;
let res: ArrayBuffer | any = null;
// TODO: we need attachments to remember which API should be used to retrieve them
if (!defaultFileserver) {
@ -61,11 +61,18 @@ export function pushToastSuccess(
export function pushLoadAttachmentFailure() {
export function pushLoadAttachmentFailure(message?: string) {
if (message) {
pushToastError(
'unableToLoadAttachment',
`${window.i18n('unableToLoadAttachment')} ${message}`
} else {
window.i18n('unableToLoadAttachment')
export function pushDangerousFileError() {