-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Track Load WordPress screen events and content export events #19719
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -101,12 +101,17 @@ private extension JetpackWindowManager { | |
func showLoadWordPressUI(schemeUrl: URL) { | ||
let actions = MigrationLoadWordPressViewModel.Actions() | ||
let loadWordPressViewModel = MigrationLoadWordPressViewModel(actions: actions) | ||
let loadWordPressViewController = MigrationLoadWordPressViewController(viewModel: loadWordPressViewModel) | ||
actions.primary = { | ||
let loadWordPressViewController = MigrationLoadWordPressViewController( | ||
viewModel: loadWordPressViewModel, | ||
tracker: migrationTracker | ||
) | ||
actions.primary = { [weak self] in | ||
self?.migrationTracker.track(.loadWordPressScreenOpenTapped) | ||
UIApplication.shared.open(schemeUrl) | ||
} | ||
actions.secondary = { [weak self] in | ||
loadWordPressViewController.dismiss(animated: true) { | ||
actions.secondary = { [weak self, weak loadWordPressViewController] in | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Adding Without the
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for spotting this! I'd had a hunch something in this area would cause a reference cycle but didn't go back to investigate. |
||
self?.migrationTracker.track(.loadWordPressScreenNoThanksTapped) | ||
loadWordPressViewController?.dismiss(animated: true) { | ||
self?.showSignInUI() | ||
} | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not that it matters but I think general style if it exists is to put them on new lines 😀