From 9258f017bf013dc090f94323b51b753e60eb93e3 Mon Sep 17 00:00:00 2001 From: WindowsMEMZ Date: Sun, 17 Nov 2024 11:31:07 +0800 Subject: [PATCH] fix: Comments with images may crash --- .../xcschemes/MeowBili Watch App.xcscheme | 3 +- .../xcschemes/MeowWidgetExtension.xcscheme | 114 ++++++++++++++++++ MeowBili/GlobalView/CommentsView.swift | 2 +- 3 files changed, 117 insertions(+), 2 deletions(-) create mode 100644 DarockBili.xcodeproj/xcshareddata/xcschemes/MeowWidgetExtension.xcscheme diff --git a/DarockBili.xcodeproj/xcshareddata/xcschemes/MeowBili Watch App.xcscheme b/DarockBili.xcodeproj/xcshareddata/xcschemes/MeowBili Watch App.xcscheme index 3c3a8487b..736917fd6 100644 --- a/DarockBili.xcodeproj/xcshareddata/xcschemes/MeowBili Watch App.xcscheme +++ b/DarockBili.xcodeproj/xcshareddata/xcschemes/MeowBili Watch App.xcscheme @@ -77,7 +77,8 @@ ignoresPersistentStateOnLaunch = "NO" debugDocumentVersioning = "YES" debugServiceExtension = "internal" - allowLocationSimulation = "YES"> + allowLocationSimulation = "YES" + notificationPayloadFile = "Examples/SDWebImage Watch Demo Extension/PushNotificationPayload.apns"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/MeowBili/GlobalView/CommentsView.swift b/MeowBili/GlobalView/CommentsView.swift index f0fb327af..e7dc85901 100644 --- a/MeowBili/GlobalView/CommentsView.swift +++ b/MeowBili/GlobalView/CommentsView.swift @@ -97,7 +97,7 @@ struct CommentsView: View { if !comments[i]["Pictures"]!.isEmpty { let picUrls = comments[i]["Pictures"]!.components(separatedBy: "|") ForEach(0..