From c7026a23540a984a8730e9d8b60c9402c44c8cb8 Mon Sep 17 00:00:00 2001
From: aerialninja <47418430+aerialninja@users.noreply.github.com>
Date: Mon, 28 Oct 2019 20:03:43 +0000
Subject: [PATCH] Add logging for authentication attempts.

---
 .../GooglePlayGames/Platforms/Android/AndroidClient.cs   | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/source/PluginDev/Assets/GooglePlayGames/Platforms/Android/AndroidClient.cs b/source/PluginDev/Assets/GooglePlayGames/Platforms/Android/AndroidClient.cs
index d028b91b7..b066093fd 100644
--- a/source/PluginDev/Assets/GooglePlayGames/Platforms/Android/AndroidClient.cs
+++ b/source/PluginDev/Assets/GooglePlayGames/Platforms/Android/AndroidClient.cs
@@ -161,7 +161,8 @@ public void Authenticate(Action<bool, string> callback, bool silent)
                                         }
 
                                         mAuthState = AuthState.Authenticated;
-                                        InvokeCallbackOnGameThread(callback, true, "Authentication succeed");
+                                        InvokeCallbackOnGameThread(callback, true, "Authentication succeeded");
+                                        GooglePlayGames.OurUtils.Logger.d("Authentication succeeded");
                                         try
                                         {
                                             using (var activationHint =
@@ -220,6 +221,7 @@ public void Authenticate(Action<bool, string> callback, bool silent)
                                     {
                                         SignOut();
                                         InvokeCallbackOnGameThread(callback, false, "Authentication failed");
+                                        GooglePlayGames.OurUtils.Logger.d("Authentication failed");
                                     }
                                 }
                             );
@@ -233,14 +235,17 @@ public void Authenticate(Action<bool, string> callback, bool silent)
                         if (result == 16 /* CommonStatusCodes.CANCELED */)
                         {
                             InvokeCallbackOnGameThread(callback, false, "Authentication canceled");
+                            GooglePlayGames.OurUtils.Logger.d("Authentication canceled");
                         }
                         else if (result == 8 /* CommonStatusCodes.DEVELOPER_ERROR */)
                         {
                             InvokeCallbackOnGameThread(callback, false, "Authentication failed - developer error");
+                            GooglePlayGames.OurUtils.Logger.d("Authentication failed - developer error");
                         }
                         else
                         {
                             InvokeCallbackOnGameThread(callback, false, "Authentication failed");
+                            GooglePlayGames.OurUtils.Logger.d("Authentication failed");
                         }
                     }
                 }
@@ -1148,4 +1153,4 @@ private AndroidJavaObject getVideosClient()
         }
     }
 }
-#endif
\ No newline at end of file
+#endif