We have implemented swipe to delete with confirmation introduced in iOS15 and now when we start showing confirmation Dialog in iOS16.1 Beta 4, the app crashes apparently when internally [UISwipeOccurrence _executeLifecycleForPerformedAction:sourceView:completionHandler:] is called.
Here is the code simplified:
List {
ForEach(items, id: \.self) { item in
ItemView(item: item)
.swipeActions {
Button(role: .destructive) {
itemToDelete = item
showDeleteConfirmation = true
} label: {
Image(systemName: "trash")
}
}
}
}
.confirmationDialog(deleteConfirmationTitle,
isPresented: $showDeleteConfirmation,
titleVisibility: .visible) {
Button(role: .destructive) {
if let itemToDelete {
withAnimation {
model.delete(itemToDelete)
}
}
} label: {
Text("Delete")
}
Button(role: .cancel) {
} label: {
Text("Cancel")
}
}
Appreciate any ideas and feedback.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
We have a notification service extension which does silent login to our backing to get and update notification content. Login response comes with HTTP header Set-Cookie which adds session cookie used to identify login session.
Then in the app we have actions registered for the corresponding category identifier. Both actions result in requests to our backend which also require session cookie.
Both extension and the app have AppGroup entitlement and use same app group.
Then we configure HTTPCookieStorage:
let cookieStorage = HTTPCookieStorage.sharedCookieStorage(forGroupContainerIdentifier:<group_id>) let configuration = URLSessionConfiguration.default configuration.httpCookieStorage = NetworkClient.cookieStorage
And we do use the very same configuration for all requests in extension / app, however when the app is spawned in the background after user taps one of the notification actions, the cookie storage in the app is empty. Although beforehand the cookie is set in the extension.
Tested with with iOS 14.4.2. Also the question would be if it is possible to activate CFNETWORK_DIAGNOSTICS in both app and extension? App works so far. But not getting logs for the extension in the console.
Appreciate any help and / or ideas.