ref(ui): Use titleLink instead of ogScrapeUrl for handling link attachment.

Signed-off-by: xsahil03x <[email protected]>
This commit is contained in:
Sahil Kumar
2021-09-16 16:41:17 +05:30
committed by xsahil03x
parent e7fc5e4133
commit 6af4e07787
8 changed files with 49 additions and 57 deletions
@@ -30,10 +30,8 @@ class UrlAttachment extends StatelessWidget {
final chatThemeData = StreamChatTheme.of(context);
return GestureDetector(
onTap: () {
launchURL(
context,
urlAttachment.ogScrapeUrl,
);
final titleLink = urlAttachment.titleLink;
if (titleLink != null) launchURL(context, titleLink);
},
child: Column(
crossAxisAlignment: CrossAxisAlignment.stretch,