Remove dead code found by Periphery on all platforms

Delete declarations that Periphery reports unused on every platform that
compiles them (iOS, macOS, tvOS), including nine views used only by their
own previews. Platform-gated code still used on another platform, device-
only MPV render paths, migration models, CloudKit record names, App
Intents metadata and unused parameters are kept.
This commit is contained in:
Arkadiusz Fal
2026-10-08 23:57:56 +02:00
parent 45e19e6536
commit 4770bbe3b9
141 changed files with 14 additions and 4191 deletions

View File

@@ -50,12 +50,9 @@ enum DetectionError: Error, Sendable {
/// Result of instance detection including type and authentication requirements.
struct InstanceDetectionResult: Sendable {
let type: InstanceType
/// Whether this instance requires authentication (Basic Auth for Yattee Server).
let requiresAuth: Bool
init(type: InstanceType, requiresAuth: Bool = false) {
self.type = type
self.requiresAuth = requiresAuth
}
}
@@ -67,27 +64,6 @@ actor InstanceDetector {
self.httpClient = httpClient
}
/// Detects the instance type for a given URL.
/// - Parameter url: The base URL of the instance.
/// - Returns: The detected instance type, or nil if detection failed.
func detect(url: URL) async -> InstanceType? {
let result = await detectWithAuth(url: url)
return result?.type
}
/// Detects the instance type and authentication requirements for a given URL.
/// - Parameter url: The base URL of the instance.
/// - Returns: The detection result including type and auth requirements, or nil if detection failed.
func detectWithAuth(url: URL) async -> InstanceDetectionResult? {
let result = await detectWithResult(url: url)
switch result {
case .success(let detectionResult):
return detectionResult
case .failure:
return nil
}
}
/// Detects the instance type with detailed error reporting.
/// - Parameters:
/// - url: The base URL of the instance.