From f1397272e5295d35b43052427b2211333de5dd06 Mon Sep 17 00:00:00 2001 From: lokeshramchand-ctrl Date: Tue, 19 Aug 2025 12:53:56 +0530 Subject: [PATCH] OHO-9(Corrections) --- Frontend/lib/email.dart | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/Frontend/lib/email.dart b/Frontend/lib/email.dart index 22d65be..fd26218 100644 --- a/Frontend/lib/email.dart +++ b/Frontend/lib/email.dart @@ -93,7 +93,7 @@ class _EmailsScreenState extends State { : Colors.green, ), title: Text( - "₹${email['amount']?.toStringAsFixed(2) ?? '---'}", + "₹${(email['amount'] is num) ? (email['amount'] as num).toStringAsFixed(2) : email['amount'] ?? '---'}", style: const TextStyle( fontSize: 18, fontWeight: FontWeight.bold, @@ -102,7 +102,17 @@ class _EmailsScreenState extends State { subtitle: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Text(email['vendor'] ?? "Unknown Vendor"), + Text( + (email['vendor'] ?? "Unknown Vendor") + .replaceAll( + RegExp( + r'[a-z0-9._%+-]+@[a-z0-9.-]+', + caseSensitive: false, + ), + '', + ) + .trim(), + ), Text( "Date: ${email['date'] ?? 'N/A'}", style: const TextStyle(fontSize: 12),