diff --git a/Secretive.xcodeproj/project.pbxproj b/Secretive.xcodeproj/project.pbxproj index e2b5406..a0a082a 100644 --- a/Secretive.xcodeproj/project.pbxproj +++ b/Secretive.xcodeproj/project.pbxproj @@ -1250,6 +1250,7 @@ MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; + OTHER_SWIFT_FLAGS = "-Xfrontend -warn-concurrency -Xfrontend -enable-actor-data-race-checks"; SDKROOT = macosx; SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; @@ -1305,6 +1306,7 @@ MACOSX_DEPLOYMENT_TARGET = 11.0; MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; + OTHER_SWIFT_FLAGS = "-Xfrontend -warn-concurrency -Xfrontend -enable-actor-data-race-checks"; SDKROOT = macosx; SWIFT_COMPILATION_MODE = wholemodule; SWIFT_OPTIMIZATION_LEVEL = "-O"; @@ -1648,6 +1650,7 @@ MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; + OTHER_SWIFT_FLAGS = "-Xfrontend -warn-concurrency -Xfrontend -enable-actor-data-race-checks"; SDKROOT = macosx; SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; SWIFT_OPTIMIZATION_LEVEL = "-Onone"; diff --git a/Secretive/Controllers/ShellConfigurationController.swift b/Secretive/Controllers/ShellConfigurationController.swift index 431e0ad..2f3e4c6 100644 --- a/Secretive/Controllers/ShellConfigurationController.swift +++ b/Secretive/Controllers/ShellConfigurationController.swift @@ -29,7 +29,7 @@ struct ShellConfigurationController { } - func addToShell(shellInstructions: ShellConfigInstruction) -> Bool { + @MainActor func addToShell(shellInstructions: ShellConfigInstruction) -> Bool { let openPanel = NSOpenPanel() // This is sync, so no need to strongly retain let delegate = Delegate(name: shellInstructions.shellConfigFilename) diff --git a/Secretive/Views/CreateSecretView.swift b/Secretive/Views/CreateSecretView.swift index 2a6689c..318226d 100644 --- a/Secretive/Views/CreateSecretView.swift +++ b/Secretive/Views/CreateSecretView.swift @@ -12,7 +12,7 @@ struct CreateSecretView: View { var body: some View { VStack { HStack { - Image(nsImage: NSApp.applicationIconImage) + Image(nsImage: NSApplication.shared.applicationIconImage) .resizable() .frame(width: 64, height: 64) .padding() diff --git a/Secretive/Views/DeleteSecretView.swift b/Secretive/Views/DeleteSecretView.swift index d9610d8..5c3bdd5 100644 --- a/Secretive/Views/DeleteSecretView.swift +++ b/Secretive/Views/DeleteSecretView.swift @@ -12,7 +12,7 @@ struct DeleteSecretView: View { var body: some View { VStack { HStack { - Image(nsImage: NSApp.applicationIconImage) + Image(nsImage: NSApplication.shared.applicationIconImage) .resizable() .frame(width: 64, height: 64) .padding() diff --git a/Secretive/Views/RenameSecretView.swift b/Secretive/Views/RenameSecretView.swift index 92977ec..9ac57ec 100644 --- a/Secretive/Views/RenameSecretView.swift +++ b/Secretive/Views/RenameSecretView.swift @@ -12,7 +12,7 @@ struct RenameSecretView: View { var body: some View { VStack { HStack { - Image(nsImage: NSApp.applicationIconImage) + Image(nsImage: NSApplication.shared.applicationIconImage) .resizable() .frame(width: 64, height: 64) .padding() diff --git a/Secretive/Views/SetupView.swift b/Secretive/Views/SetupView.swift index 8a17a0c..9329608 100644 --- a/Secretive/Views/SetupView.swift +++ b/Secretive/Views/SetupView.swift @@ -146,7 +146,7 @@ struct SecretAgentSetupView: View { var body: some View { SetupStepView(title: "Setup Secret Agent", - image: Image(nsImage: NSApp.applicationIconImage), + image: Image(nsImage: NSApplication.shared.applicationIconImage), bodyText: "Secretive needs to set up a helper app to work properly. It will sign requests from SSH clients in the background, so you don't need to keep the main Secretive app open.", buttonTitle: "Install", buttonAction: install) {