@@ -26,11 +26,21 @@ public sealed class FirebaseAccountLinkException : System.Exception
2626{
2727 /// Initializes a new FirebaseAccountLinkException, with the given error code and
2828 /// message and the AdditionalUserInfo returned from the Firebase auth service.
29+ [ System . Obsolete ( "Use `FirebaseAccountLinkException(int, string, AuthResult)` instead" , false ) ]
2930 public FirebaseAccountLinkException ( int errorCode , string message ,
3031 SignInResult signInResult ) : base ( message )
3132 {
3233 ErrorCode = errorCode ;
33- Result = signInResult ;
34+ result_DEPRECATED = signInResult ;
35+ }
36+
37+ /// Initializes a new FirebaseAccountLinkException, with the given error code and
38+ /// message and the AdditionalUserInfo returned from the Firebase auth service.
39+ public FirebaseAccountLinkException ( int errorCode , string message ,
40+ AuthResult authResult ) : base ( message )
41+ {
42+ ErrorCode = errorCode ;
43+ result = authResult ;
3444 }
3545
3646 /// Returns the Auth defined non-zero error code.
@@ -43,10 +53,12 @@ public FirebaseAccountLinkException(int errorCode, string message,
4353 /// the credential may be used to sign-in the user into Firebase with
4454 /// Firebase.Auth.SignInWithCredentialAsync.
4555 public AdditionalUserInfo UserInfo {
46- get { return Result . Info ; }
56+ get { return ( result != null ) ? result . AdditionalUserInfoInternal :
57+ ( result_DEPRECATED != null ) ? result_DEPRECATED . Info : null ; }
4758 }
4859
49- private SignInResult Result { get ; set ; }
60+ private SignInResult result_DEPRECATED = null ;
61+ private AuthResult result = null ;
5062}
5163
5264}
0 commit comments