Skip to content

Commit

Permalink
chore: migrate getFileUrlFromMessage to ts (RocketChat#3734)
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexAlexandre authored Feb 21, 2022
1 parent 04b6dc9 commit 0ddfa32
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export default function (message) {
export default function (message: { type: string; url: string }) {
if (/image/.test(message.type)) {
return { image_url: message.url };
}
Expand Down
2 changes: 2 additions & 0 deletions app/views/MessagesView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ interface IMessageItem {
msg?: string;
starred: boolean;
pinned: boolean;
type: string;
url: string;
}

interface IParams {
Expand Down

0 comments on commit 0ddfa32

Please sign in to comment.