Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion auth/src/android/common_android.cc
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ static const ErrorCodeMapping kWebCodes[] = {
kAuthErrorWebContextAlreadyPresented},
{"ERROR_WEB_CONTEXT_CANCELED", kAuthErrorWebContextCancelled},
{"ERROR_WEB_INTERNAL_ERROR", kAuthErrorWebInternalError},
{"ERROR_WEB_STORAGE_UNSUPPORTED", kAuthErrorWebStorateUnsupported},
{"ERROR_WEB_STORAGE_UNSUPPORTED", kAuthErrorWebStorageUnsupported},
{nullptr},
};
static const ErrorCodeMapping kFirebaseAuthCodes[] = {
Expand Down
2 changes: 1 addition & 1 deletion auth/src/desktop/auth_providers/federated_auth_provider.cc
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Future<AuthResult> CreateAuthFuture(AuthData* auth_data,
SafeFutureHandle<AuthResult> handle =
auth_data->future_impl.SafeAlloc<AuthResult>(api_function);
auth_data->future_impl.CompleteWithResult(
handle, kAuthErrorFederatedProviderAreadyInUse,
handle, kAuthErrorFederatedProviderAlreadyInUse,
"Provider operation already in progress.",
/*result=*/{});
return MakeFuture(&auth_data->future_impl, handle);
Expand Down
14 changes: 7 additions & 7 deletions auth/src/include/firebase/auth/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ enum AuthError {
/// Caused by "Set account info" methods.
kAuthErrorEmailAlreadyInUse,

/// Indicates the user has attemped to change email or password more than 5
/// Indicates the user has attempted to change email or password more than 5
/// minutes after signing in, and will need to refresh the credentials.
/// Caused by "Set account info" methods.
kAuthErrorRequiresRecentLogin,
Expand Down Expand Up @@ -319,7 +319,7 @@ enum AuthError {

/// Indicates that 3rd party cookies or data are disabled, or that there was
/// a problem with the browser.
kAuthErrorWebStorateUnsupported,
kAuthErrorWebStorageUnsupported,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Renaming kAuthErrorWebStorateUnsupported to kAuthErrorWebStorageUnsupported is a breaking change for public APIs. To maintain backward compatibility for existing clients, consider keeping the old misspelled name as a deprecated alias pointing to the new name.

Suggested change
kAuthErrorWebStorageUnsupported,
kAuthErrorWebStorageUnsupported,
kAuthErrorWebStorateUnsupported = kAuthErrorWebStorageUnsupported,

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It sure is


/// Indicates that the provided tenant ID does not match the Auth instance's
/// tenant ID.
Expand Down Expand Up @@ -400,7 +400,7 @@ enum AuthError {
/// Indicates that the federated provider is busy with a previous
/// authorization request. Try again when the previous authorization request
/// completes.
kAuthErrorFederatedProviderAreadyInUse,
kAuthErrorFederatedProviderAlreadyInUse,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Renaming kAuthErrorFederatedProviderAreadyInUse to kAuthErrorFederatedProviderAlreadyInUse is a breaking change for public APIs. To maintain backward compatibility for existing clients, consider keeping the old misspelled name as a deprecated alias pointing to the new name.

Suggested change
kAuthErrorFederatedProviderAlreadyInUse,
kAuthErrorFederatedProviderAlreadyInUse,
kAuthErrorFederatedProviderAreadyInUse = kAuthErrorFederatedProviderAlreadyInUse,

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It sure is a breaking change


/// Indicates that one or more fields of the provided AuthenticatedUserData
/// are invalid.
Expand All @@ -427,7 +427,7 @@ enum AuthError {
/// nor a custom token provider is available.
kAuthErrorTokenRefreshUnavailable,

#endif // INTERNAL_EXEPERIMENTAL
#endif // INTERNAL_EXPERIMENTAL
};

/// @brief Contains information required to authenticate with a third party
Expand All @@ -438,9 +438,9 @@ struct FederatedProviderData {
std::string provider_id;
};

/// @brief Contains information to identify an OAuth povider.
/// @brief Contains information to identify an OAuth provider.
struct FederatedOAuthProviderData : FederatedProviderData {
/// Initailizes an empty provider data structure.
/// Initializes an empty provider data structure.
FederatedOAuthProviderData() {}

/// Initializes the provider data structure with a provider id.
Expand All @@ -460,7 +460,7 @@ struct FederatedOAuthProviderData : FederatedProviderData {
}
#endif

/// OAuth parmeters which specify which rights of access are being requested.
/// OAuth parameters which specify which rights of access are being requested.
std::vector<std::string> scopes;

/// OAuth parameters which are provided to the federated provider service.
Expand Down
2 changes: 1 addition & 1 deletion auth/tests/desktop/auth_desktop_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ TEST_F(AuthDesktopTest,
Future<AuthResult> future1 = firebase_auth_->SignInWithProvider(&provider1);
EXPECT_EQ(future1.status(), kFutureStatusPending);
Future<AuthResult> future2 = firebase_auth_->SignInWithProvider(&provider2);
VerifyAuthResult(future2, kAuthErrorFederatedProviderAreadyInUse);
VerifyAuthResult(future2, kAuthErrorFederatedProviderAlreadyInUse);
handler1.TriggerSignInComplete();
const AuthResult result = WaitForFuture(future1);
}
Expand Down
4 changes: 2 additions & 2 deletions auth/tests/desktop/user_desktop_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -891,7 +891,7 @@ TEST_F(UserDesktopTest,
Future<AuthResult> future1 = firebase_user_.LinkWithProvider(&provider1);
EXPECT_EQ(future1.status(), kFutureStatusPending);
Future<AuthResult> future2 = firebase_user_.LinkWithProvider(&provider2);
VerifyAuthResult(future2, kAuthErrorFederatedProviderAreadyInUse);
VerifyAuthResult(future2, kAuthErrorFederatedProviderAlreadyInUse);
handler1.TriggerLinkComplete();
const AuthResult result = WaitForFuture(future1);
}
Expand Down Expand Up @@ -1054,7 +1054,7 @@ TEST_F(UserDesktopTest,
EXPECT_EQ(future1.status(), kFutureStatusPending);
Future<AuthResult> future2 =
firebase_user_.ReauthenticateWithProvider(&provider2);
VerifyAuthResult(future2, kAuthErrorFederatedProviderAreadyInUse);
VerifyAuthResult(future2, kAuthErrorFederatedProviderAlreadyInUse);
handler1.TriggerReauthenticateComplete();
const AuthResult result = WaitForFuture(future1);
}
Expand Down
4 changes: 4 additions & 0 deletions release_build_files/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -613,6 +613,10 @@ workflow use only during the development of your app, not for publicly shipping
code.

## Release Notes
### Upcoming
- Changes
- Auth: **Breaking Change:** Fixed spelling in `AuthError` enum values (`kAuthErrorWebStorateUnsupported` -> `kAuthErrorWebStorageUnsupported` and `kAuthErrorFederatedProviderAreadyInUse` -> `kAuthErrorFederatedProviderAlreadyInUse`).

### 13.13.0
- Changes
- General (Android): Update to Firebase Android BoM version 34.19.0.
Expand Down
Loading