Skip to content

Commit

Permalink
Update src/components/AttachmentCarousel/index.js
Browse files Browse the repository at this point in the history
Co-authored-by: Carlos Martins <luacmartins@gmail.com>
  • Loading branch information
JediWattson and luacmartins authored Jan 16, 2023
1 parent aef4993 commit 50143fb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/components/AttachmentCarousel/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,9 @@ class AttachmentCarousel extends React.Component {
*/
const attachments = [];
_.forEach(actions, ({originalMessage}) => {
if (!originalMessage || !originalMessage.html) { return; }
if (!originalMessage || !originalMessage.html) {
return;
}
const matches = [...originalMessage.html.matchAll(CONST.REGEX.ATTACHMENT_DATA)];

// matchAll captured both source url and name of the attachment
Expand Down

0 comments on commit 50143fb

Please sign in to comment.