Skip to content

Commit 62150e7

Browse files
Yue-Wang-Googlerenkelvin
authored andcommitted
Expose authdataresult.credential.secret in public header. (#3089)
1 parent d723fc4 commit 62150e7

File tree

4 files changed

+15
-13
lines changed

4 files changed

+15
-13
lines changed

Firebase/Auth/Source/Auth/FIRAuthDataResult_Internal.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,6 @@ NS_ASSUME_NONNULL_BEGIN
2222

2323
@interface FIRAuthDataResult () <NSSecureCoding>
2424

25-
/** @property credential
26-
@brief The updated OAuth credential after the sign-in, link and reauthenticate action.
27-
@detail This property is for OAuth sign in only.
28-
*/
29-
@property(nonatomic, readonly, nullable) FIROAuthCredential *credential;
30-
3125
/** @fn initWithUser:additionalUserInfo:
3226
@brief Designated initializer.
3327
@param user The signed in user reference.

Firebase/Auth/Source/AuthProvider/OAuth/FIROAuthCredential_Internal.h

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,6 @@ NS_ASSUME_NONNULL_BEGIN
4242
*/
4343
@property(nonatomic, readonly, nullable) NSString *pendingToken;
4444

45-
/** @property secret
46-
@brief The secret associated with this credential. This will be nil for OAuth 2.0 providers.
47-
@detail OAuthCredential already exposes a providerId getter. This will help the developer
48-
determine whether an access token/secret pair is needed.
49-
*/
50-
@property(nonatomic, readonly, nullable) NSString *secret;
51-
5245
/** @fn initWithProviderId:IDToken:accessToken:secret:pendingToken
5346
@brief Designated initializer.
5447
@param providerID The provider ID associated with the credential being created.

Firebase/Auth/Source/Public/FIRAuthDataResult.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#import <Foundation/Foundation.h>
1818

1919
@class FIRAdditionalUserInfo;
20+
@class FIRAuthCredential;
2021
@class FIRUser;
2122

2223
NS_ASSUME_NONNULL_BEGIN
@@ -44,6 +45,13 @@ NS_SWIFT_NAME(AuthDataResult)
4445
*/
4546
@property(nonatomic, readonly, nullable) FIRAdditionalUserInfo *additionalUserInfo;
4647

48+
/** @property credential
49+
@brief This property will be non-nil after a successful headful-lite sign-in via
50+
signInWithProvider:UIDelegate:. May be used to obtain the accessToken and/or IDToken
51+
pertaining to a recently signed-in user.
52+
*/
53+
@property(nonatomic, readonly, nullable) FIRAuthCredential *credential;
54+
4755
@end
4856

4957
NS_ASSUME_NONNULL_END

Firebase/Auth/Source/Public/FIROAuthCredential.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,13 @@ NS_SWIFT_NAME(OAuthCredential)
3636
*/
3737
@property(nonatomic, readonly, nullable) NSString *accessToken;
3838

39+
/** @property secret
40+
@brief The secret associated with this credential. This will be nil for OAuth 2.0 providers.
41+
@detail OAuthCredential already exposes a providerId getter. This will help the developer
42+
determine whether an access token/secret pair is needed.
43+
*/
44+
@property(nonatomic, readonly, nullable) NSString *secret;
45+
3946
/** @fn init
4047
@brief This class is not supposed to be instantiated directly.
4148
*/

0 commit comments

Comments
 (0)