@@ -62,7 +62,6 @@ class AuthenticationManager: Authentication {
6262 let isWPComMagicLinkPreferredToPassword = featureFlagService. isFeatureFlagEnabled ( . loginMagicLinkEmphasis)
6363 let isWPComMagicLinkShownAsSecondaryActionOnPasswordScreen = featureFlagService. isFeatureFlagEnabled ( . loginMagicLinkEmphasisM2)
6464 let isStoreCreationMVPEnabled = featureFlagService. isFeatureFlagEnabled ( . storeCreationMVP)
65- let isNativeJetpackSetupEnabled = ABTest . nativeJetpackSetupFlow. variation != . control
6665 let isWPComLoginRequiredForSiteCredentialsLogin = !featureFlagService. isFeatureFlagEnabled ( . applicationPasswordAuthenticationForSiteCredentialLogin)
6766 let configuration = WordPressAuthenticatorConfiguration ( wpcomClientId: ApiCredentials . dotcomAppId,
6867 wpcomSecret: ApiCredentials . dotcomSecret,
@@ -91,7 +90,7 @@ class AuthenticationManager: Authentication {
9190 emphasizeEmailForWPComPassword: true ,
9291 wpcomPasswordInstructions:
9392 AuthenticationConstants . wpcomPasswordInstructions,
94- skipXMLRPCCheckForSiteDiscovery: isNativeJetpackSetupEnabled )
93+ skipXMLRPCCheckForSiteDiscovery: true )
9594
9695 let systemGray3LightModeColor = UIColor ( red: 199 / 255.0 , green: 199 / 255.0 , blue: 204 / 255.0 , alpha: 1 )
9796 let systemLabelLightModeColor = UIColor ( red: 0 , green: 0 , blue: 0 , alpha: 1 )
@@ -664,39 +663,6 @@ private extension AuthenticationManager {
664663 }
665664 }
666665
667- /// The error screen to be displayed when the user enters a site
668- /// without Jetpack in the site discovery flow.
669- /// More about this flow: pe5sF9-mz-p2.
670- ///
671- func jetpackErrorUI( for siteURL: String , with matcher: ULAccountMatcher , in navigationController: UINavigationController ) -> UIViewController {
672- let viewModel = JetpackErrorViewModel ( siteURL: siteURL,
673- siteCredentials: nil ,
674- onJetpackSetupCompletion: { [ weak self] authorizedEmailAddress in
675- guard let self = self else { return }
676-
677- // Tries re-syncing to get an updated store list
678- ServiceLocator . stores. synchronizeEntities { [ weak self] in
679- guard let self = self else { return }
680- matcher. refreshStoredSites ( )
681- guard let matchedSite = matcher. matchedSite ( originalURL: siteURL) else {
682- DDLogWarn ( " ⚠️ Could not find \( siteURL) connected to the account " )
683- return
684- }
685- // checks if the site has woo
686- if matchedSite. isWooCommerceActive == false {
687- let noWooUI = self . noWooUI ( for: matchedSite,
688- with: matcher,
689- navigationController: navigationController,
690- onStorePickerDismiss: { } )
691- navigationController. show ( noWooUI, sender: nil )
692- } else {
693- self . startStorePicker ( with: matchedSite. siteID, in: navigationController, onDismiss: { } )
694- }
695- }
696- } )
697- return ULErrorViewController ( viewModel: viewModel)
698- }
699-
700666 /// The error screen to be displayed when the user tries to enter a site
701667 /// whose Jetpack is not associated with their account.
702668 /// - Parameters:
@@ -777,18 +743,9 @@ private extension AuthenticationManager {
777743 }
778744
779745 // Shows the native Jetpack flow during the site discovery flow.
780- if ABTest . nativeJetpackSetupFlow. variation != . control {
781- return jetpackSetupUI ( for: site. url,
782- connectionMissingOnly: site. hasJetpack && site. isJetpackActive,
783- in: navigationController)
784- }
785-
786- /// Jetpack is required. Present an error if we don't detect a valid installation.
787- guard site. hasJetpack && site. isJetpackActive else {
788- return jetpackErrorUI ( for: site. url, with: matcher, in: navigationController)
789- }
790-
791- return accountMismatchUI ( for: site. url, siteCredentials: nil , with: matcher, in: navigationController)
746+ return jetpackSetupUI ( for: site. url,
747+ connectionMissingOnly: site. hasJetpack && site. isJetpackActive,
748+ in: navigationController)
792749 }
793750
794751 /// Checks if the authenticated user is eligible to use the app and navigates to the home screen.
0 commit comments