Move ErrorLog stuff to its own module. Extend it to report errors for components other than Accounts.

This commit is contained in:
Brent Simmons committed 2026-03-12 19:27:56 -07:00
1 parent ef8c8af43d
commit 5c7b8cff07
7 files changed
+213 -79

No files matched your search

@@ -0,0 +1,22 @@
//
// ErrorLogNotification.swift
// ErrorLog
//
// Created by Brent Simmons on 3/12/26.
//
import Foundation
public extension Notification.Name {
/// Posted when any component encounters an error that should be logged.
/// UserInfo keys are defined in ErrorLogUserInfoKey.
static let appDidEncounterError = Notification.Name(rawValue: "AppDidEncounterErrorNotification")
}
public struct ErrorLogUserInfoKey {
public static let sourceName = "sourceName"
public static let sourceID = "sourceID" // 0-99 are AccountType raw values. 100 and greater are for other components.
public static let errorMessage = "errorMessage"
}