From dffea5122318a7f75e31dfc79e2acce0c37cb757 Mon Sep 17 00:00:00 2001 From: bggRGjQaUbCoE Date: Mon, 23 Dec 2024 17:26:36 +0800 Subject: [PATCH] fix: whisper page: pass none null mid Signed-off-by: bggRGjQaUbCoE --- lib/pages/whisper/view.dart | 10 ++++++---- lib/pages/whisper_detail/controller.dart | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/lib/pages/whisper/view.dart b/lib/pages/whisper/view.dart index 103c45c5..f6eb27cd 100644 --- a/lib/pages/whisper/view.dart +++ b/lib/pages/whisper/view.dart @@ -249,10 +249,12 @@ class _WhisperPageState extends State { sessionList[i].accountInfo.name, 'face': sessionList[i].accountInfo.face, - 'mid': sessionList[i] - .accountInfo - .mid - .toString(), + if (sessionList[i].accountInfo.mid != + null) + 'mid': sessionList[i] + .accountInfo + .mid + .toString(), }, ); }, diff --git a/lib/pages/whisper_detail/controller.dart b/lib/pages/whisper_detail/controller.dart index 8bd9d81c..7589af1f 100644 --- a/lib/pages/whisper_detail/controller.dart +++ b/lib/pages/whisper_detail/controller.dart @@ -26,7 +26,7 @@ class WhisperDetailController extends GetxController { talkerId = int.parse(Get.parameters['talkerId']!); name = Get.parameters['name']!; face = Get.parameters['face']!; - mid = Get.parameters['mid']!; + mid = Get.parameters['mid']; querySessionMsg(); }