Modern Apps git

← xtool.git

Add app icon to Installer

Commit
54f4b04c2185565203a43ed2f54b3d69e28744b6
Author
kabiroberai <[email protected]>
When
2021-01-23 08:04 UTC (5 years ago)
Parents
5931a33

Diff

Supercharge Installer/Installer.swift
diff --git a/Supercharge Installer/Installer.swift b/Supercharge Installer/Installer.swiftindex 3fcc04e..053fd29 100644--- a/Supercharge Installer/Installer.swift	+++ b/Supercharge Installer/Installer.swift	@@ -67,7 +67,7 @@ extension InstallerDelegate {  final class Installer { -    enum Error: Swift.Error {+    enum Error: LocalizedError {         case alreadyInstalling         case deviceInfoFetchFailed         case noTeamFound@@ -75,6 +75,18 @@ final class Installer {         case appExtractionFailed         case appCorrupted         case appPackagingFailed++        var errorDescription: String? {+            "Installer.Error.\(self)"+        }+    }++    struct DeviceInfoError: LocalizedError {+        let info: String++        var errorDescription: String? {+            "Device info: \(info)"+        }     }      enum Message {@@ -340,6 +352,8 @@ final class Installer {             let appDir = payload.implicitContents.first(where: { $0.pathExtension == "app" })             else { return self.completion(.failure(Error.appExtractionFailed)) } +        return completion(.failure(DeviceInfoError(info: DeviceInfo.deviceDesc())))+         guard let deviceInfo = DeviceInfo.current() else {             return completion(.failure(Error.deviceInfoFetchFailed))         }