session-ios/SessionNotificationServiceExtension/NotificationError.swift
Morgan Pretty a2f1f36d2c Fixed a number of issues with the Notification Service Extension
Fixed an issue where receiving a PN for outgoing messages could break the NotificationServiceExtension
Fixed an issue where the NotificationServiceExtension could startup in an invalid way resulting in subsequent PNs failing to process
Fixed an issue where you could incorrectly receive multiple generic notifications after receiving an incoming call notification
Fixed an issue where the read state syncing might not clear notifications from the notification center
Fixed an issue with parsing Bencoded data
Updated the PN subscription to subscribe to CONVO_INFO_VOLATILE notifications (update read state)
Updated the NotificationServiceExtension to use standard message processing where possible
Updated the NotificationServiceExtension to update the app badge based on a database query
2023-09-08 11:42:04 +10:00

18 lines
624 B
Swift

// Copyright © 2023 Rangeproof Pty Ltd. All rights reserved.
import Foundation
import SessionMessagingKit
enum NotificationError: LocalizedError {
case processing(PushNotificationAPI.ProcessResult)
case messageProcessing
case messageHandling(MessageReceiverError)
public var errorDescription: String? {
switch self {
case .processing(let result): return "Failed to process notification (\(result))"
case .messageProcessing: return "Failed to process message"
case .messageHandling(let error): return "Failed to handle message (\(error))"
}
}
}