From 0192668c63c32943bc55fe8000e61196ee30d683 Mon Sep 17 00:00:00 2001 From: Naif-Deriv Date: Wed, 3 Jul 2024 14:42:44 +0400 Subject: [PATCH 1/2] add default token login tracking. --- .../lib/core/analytics/data/auth_tracking_data.dart | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart b/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart index 9ac3b2559..d0753614b 100644 --- a/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart +++ b/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart @@ -160,5 +160,12 @@ Map _getLoginErrorTrackingData( 'error_message': errorMessage, }, }, - null => throw Exception('Null LoginProvider is being passed.'), + null => { + 'event': 'login_flow_error', + 'properties': { + 'app_id': appId, + 'login_provider': 'deafult_token', + 'error_message': errorMessage, + }, + }, }; From 4495c984fa5a411af87b15d69b494761ac5e19d4 Mon Sep 17 00:00:00 2001 From: Naif-Deriv Date: Thu, 4 Jul 2024 10:54:27 +0400 Subject: [PATCH 2/2] fix typo. --- .../deriv_auth/lib/core/analytics/data/auth_tracking_data.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart b/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart index d0753614b..b3c754c39 100644 --- a/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart +++ b/packages/deriv_auth/lib/core/analytics/data/auth_tracking_data.dart @@ -164,7 +164,7 @@ Map _getLoginErrorTrackingData( 'event': 'login_flow_error', 'properties': { 'app_id': appId, - 'login_provider': 'deafult_token', + 'login_provider': 'default_token', 'error_message': errorMessage, }, },