فهرست منبع

Fix: log stacktrace with error

Neeraj Gupta 2 سال پیش
والد
کامیت
cf092f6fde
1فایلهای تغییر یافته به همراه6 افزوده شده و 2 حذف شده
  1. 6 2
      lib/ui/shared_collections_gallery.dart

+ 6 - 2
lib/ui/shared_collections_gallery.dart

@@ -111,8 +111,12 @@ class _SharedCollectionGalleryState extends State<SharedCollectionGallery>
         if (snapshot.hasData) {
           return _getSharedCollectionsGallery(snapshot.data!);
         } else if (snapshot.hasError) {
-          _logger.shout(snapshot.error);
-          return Center(child: Text(snapshot.error.toString()));
+          _logger.severe(
+            "critical: failed to load share gallery",
+            snapshot.error,
+            snapshot.stackTrace,
+          );
+          return const Center(child: Text("Something went wrong."));
         } else {
           return const EnteLoadingWidget();
         }