Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -237,10 +237,6 @@ NS_SWIFT_NAME(SalesforceManager)
*/
@property (nonatomic, assign) BOOL useWebServerAuthentication;

/** Whether or not the app supports welcome discovery, this should only be enabled if the connected app is supported.
*/
@property (nonatomic, assign) BOOL supportsWelcomeDiscovery;

/** Whether hybrid authentication flow should be used. Defaults to YES.
*/
@property (nonatomic, assign) BOOL useHybridAuthentication;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,6 @@ - (instancetype)init {
self.useWebServerAuthentication = YES;
self.blockSalesforceIntegrationUser = NO;
self.useHybridAuthentication = YES;
self.supportsWelcomeDiscovery = NO;
[self setupServiceConfiguration];
_snapshotViewControllers = [SFSDKSafeMutableDictionary new];
_nativeLoginViewControllers = [SFSDKSafeMutableDictionary new];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,7 @@ public class DomainDiscoveryCoordinator: NSObject {
public func isDiscoveryDomain(_ domain: String?) -> Bool {
guard let domain = domain else { return false }
let isDiscovery = domain.lowercased().contains(DomainDiscovery.URLComponent.path.rawValue)
let discoveryEnabled = SalesforceManager.shared.supportsWelcomeDiscovery
if isDiscovery && !discoveryEnabled {
SFSDKCoreLogger.w(classForCoder, message: "\(domain) is a discovery domain, but welcome discovery isn't enabled.")
}
return isDiscovery && discoveryEnabled
return isDiscovery
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -155,15 +155,4 @@ final class DomainDiscoveryCoordinatorTests: XCTestCase {
XCTAssertEqual(results?.myDomain, expectedDomain)
XCTAssertEqual(results?.loginHint, expectedLoginHint)
}

func testDiscoveryFlag() throws {
let coordinator = DomainDiscoveryCoordinator()
let domain = "welcome.salesforce.com/discovery"

SalesforceManager.shared.supportsWelcomeDiscovery = false
XCTAssertFalse(coordinator.isDiscoveryDomain(domain))

SalesforceManager.shared.supportsWelcomeDiscovery = true
XCTAssertTrue(coordinator.isDiscoveryDomain(domain))
}
}
Loading