File tree Expand file tree Collapse file tree 3 files changed +29
-12
lines changed
Utility/App Configuration
ViewRelated/Jetpack/Branding/Coordinator Expand file tree Collapse file tree 3 files changed +29
-12
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,20 @@ import WordPressAuthenticator
2727 #endif
2828 #endif
2929 #endif
30+
31+ /// Deep Link URL Scheme
32+ ///
33+ /// Note: This needs to be manually in sync with Target > Build Settings > User-defined > `WPCOM_SCHEME`.
34+ ///
35+ #if DEBUG
36+ static let deepLinkScheme = " wpdebug "
37+ #elseif INTERNAL_BUILD
38+ static let deepLinkScheme = " wpinternal "
39+ #elseif ALPHA_BUILD
40+ static let deepLinkScheme = " wpalpha "
41+ #else
42+ static let deepLinkScheme = " wordpress "
43+ #endif
3044}
3145
3246// MARK: - Tab bar order
Original file line number Diff line number Diff line change @@ -6,18 +6,7 @@ class JetpackBrandingCoordinator {
66 static func presentOverlay( from viewController: UIViewController , redirectAction: ( ( ) -> Void ) ? = nil ) {
77
88 let action = redirectAction ?? {
9- #if DEBUG
10- let jetpackScheme = " jpdebug "
11- #elseif INTERNAL_BUILD
12- let jetpackScheme = " jpinternal "
13- #elseif ALPHA_BUILD
14- let jetpackScheme = " jpalpha "
15- #else
16- let jetpackScheme = " jetpack "
17- #endif
18-
19- guard AppConfiguration . isWordPress,
20- let jetpackDeepLinkURL = URL ( string: " \( jetpackScheme) ://app " ) ,
9+ guard let jetpackDeepLinkURL = URL ( string: " \( AppConstants . deepLinkScheme) ://app " ) ,
2110 let jetpackUniversalLinkURL = URL ( string: " https://jetpack.com/app " ) ,
2211 let jetpackAppStoreURL = URL ( string: " https://apps.apple.com/app/jetpack-website-builder/id1565481562 " ) else {
2312 return
Original file line number Diff line number Diff line change @@ -27,6 +27,20 @@ import WordPressKit
2727 #endif
2828 #endif
2929 #endif
30+
31+ /// Deep Link URL Scheme
32+ ///
33+ /// Note: this needs to be in sync with Target > Build Settings > User-defined > `WPCOM_SCHEME` value.
34+ ///
35+ #if DEBUG
36+ static let deepLinkScheme = " jpdebug "
37+ #elseif INTERNAL_BUILD
38+ static let deepLinkScheme = " jpinternal "
39+ #elseif ALPHA_BUILD
40+ static let deepLinkScheme = " jpalpha "
41+ #else
42+ static let deepLinkScheme = " jetpack "
43+ #endif
3044}
3145
3246// MARK: - Tab bar order
You can’t perform that action at this time.
0 commit comments