Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions app/views/AttachmentView.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,9 @@ class AttachmentView extends React.Component {
const { attachment } = this.state;
const { user, baseUrl } = this.props;
const {
image_url, image_type, video_url, video_type
title_link, image_url, image_type, video_url, video_type
} = attachment;
const url = image_url || video_url;
const url = title_link || image_url || video_url;
const mediaAttachment = formatAttachmentUrl(url, user.id, user.token, baseUrl);

if (isAndroid) {
Expand Down Expand Up @@ -170,7 +170,7 @@ class AttachmentView extends React.Component {
let content = null;

if (attachment && attachment.image_url) {
const uri = formatAttachmentUrl(attachment.image_url, user.id, user.token, baseUrl);
const uri = formatAttachmentUrl(attachment.title_link || attachment.image_url, user.id, user.token, baseUrl);
content = this.renderImage(encodeURI(uri));
} else if (attachment && attachment.video_url) {
const uri = formatAttachmentUrl(attachment.video_url, user.id, user.token, baseUrl);
Expand Down