From d60f9634988e079462e141997976e7f164f48be1 Mon Sep 17 00:00:00 2001 From: Soner Yuksel Date: Thu, 15 Jul 2021 10:51:55 -0400 Subject: [PATCH] Feedback related with security --- Client/Application/Delegates/AppDelegate.swift | 4 ++-- Client/Application/Shortcuts/ActivityShortcutManager.swift | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Client/Application/Delegates/AppDelegate.swift b/Client/Application/Delegates/AppDelegate.swift index 511750e10cb..ce2efdd79cb 100644 --- a/Client/Application/Delegates/AppDelegate.swift +++ b/Client/Application/Delegates/AppDelegate.swift @@ -635,7 +635,7 @@ extension AppDelegate { if let userInfo = userActivity.userInfo, let urlString = userInfo[CSSearchableItemActivityIdentifier] as? String, let url = URL(string: urlString) { - browserViewController.switchToTabForURLOrOpen(url, isPrivileged: true) + browserViewController.switchToTabForURLOrOpen(url, isPrivileged: false) return true } case ActivityType.newTab.identifier: @@ -677,7 +677,7 @@ extension AppDelegate { return false } - browserViewController.switchToTabForURLOrOpen(url, isPrivileged: true) + browserViewController.switchToTabForURLOrOpen(url, isPrivileged: false) return true } diff --git a/Client/Application/Shortcuts/ActivityShortcutManager.swift b/Client/Application/Shortcuts/ActivityShortcutManager.swift index 6269dd8305b..e6734b99fd7 100644 --- a/Client/Application/Shortcuts/ActivityShortcutManager.swift +++ b/Client/Application/Shortcuts/ActivityShortcutManager.swift @@ -192,6 +192,10 @@ class ActivityShortcutManager: NSObject { // MARK: Intent Donation Methods public func donateCustomIntent(for type: IntentType, with urlString: String) { + guard !PrivateBrowsingManager.shared.isPrivateBrowsing else { + return + } + let intent = createCustomIntent(for: type, with: urlString) let interaction = INInteraction(intent: intent, response: nil)