From 9ac488c9c5b595718a0954a3e60caf3f2063d4ad Mon Sep 17 00:00:00 2001 From: Oguz Yuksel <74555694+OguzYuuksel@users.noreply.github.com> Date: Thu, 10 Oct 2024 15:04:12 +0200 Subject: [PATCH] modernize ApplicationOpener (#74) Co-authored-by: Oguz Yuksel --- Sources/UIExtensions/Helpers/ApplicationOpener.swift | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Sources/UIExtensions/Helpers/ApplicationOpener.swift b/Sources/UIExtensions/Helpers/ApplicationOpener.swift index 9f66585..81817c6 100644 --- a/Sources/UIExtensions/Helpers/ApplicationOpener.swift +++ b/Sources/UIExtensions/Helpers/ApplicationOpener.swift @@ -4,14 +4,15 @@ import Foundation import UIKit -@objc @MainActor public protocol ApplicationOpener { nonisolated var openSettingsURL: String { get } nonisolated func canOpenURL(_ url: URL) -> Bool @available(iOSApplicationExtension, unavailable) - @objc(openURL:options:completionHandler:) func open(_ url: URL, options: [UIApplication.OpenExternalURLOptionsKey: Any], completionHandler completion: (@MainActor @Sendable (Bool) -> Void)?) + @available(iOSApplicationExtension, unavailable) + @discardableResult + func open(_ url: URL, options: [UIApplication.OpenExternalURLOptionsKey: Any]) async -> Bool } @available(iOSApplicationExtension, unavailable)