Skip to content
This repository was archived by the owner on Feb 5, 2025. It is now read-only.

Commit 675442e

Browse files
committed
Adding 'source' property to signupSocialFailure tracks.
1 parent 1b8bfbe commit 675442e

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

WordPressAuthenticator/Signin/AppleAuthenticator.swift

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,12 @@ private extension AppleAuthenticator {
139139

140140
func signupFailed(with error: Error) {
141141
DDLogError("Apple Authenticator: Signup failed. error: \(error.localizedDescription)")
142-
WordPressAuthenticator.track(.signupSocialFailure, error: error)
142+
143+
let properties = [ "source": "apple",
144+
"error": error.localizedDescription
145+
]
146+
147+
WordPressAuthenticator.track(.signupSocialFailure, properties: properties)
143148
delegate?.authFailedWithError(message: error.localizedDescription)
144149
}
145150

WordPressAuthenticator/Signup/SignupGoogleViewController.swift

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,12 @@ private extension SignupGoogleViewController {
150150
/// Social Signup Failure: Analytics + UI Updates
151151
///
152152
func socialSignupDidFail(with error: Error) {
153-
WordPressAuthenticator.track(.signupSocialFailure, error: error)
153+
154+
let properties = [ "source": "google",
155+
"error": error.localizedDescription
156+
]
157+
158+
WordPressAuthenticator.track(.signupSocialFailure, properties: properties)
154159

155160
if (error as? SignupError) == .unknown {
156161
navigationController?.popViewController(animated: true)

0 commit comments

Comments
 (0)