Skip to content

Commit cdeb9be

Browse files
committed
[AUTOMATED]: Prettier Code Styling
1 parent 20c1cfb commit cdeb9be

File tree

5 files changed

+25
-19
lines changed

5 files changed

+25
-19
lines changed

packages-exp/auth-exp/src/api/account_management/account.test.ts

+14-10
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ describe('deleteAccount', () => {
6666

6767
await expect(deleteAccount(mockAuth, request)).to.be.rejectedWith(
6868
FirebaseError,
69-
'Firebase: This user\'s credential isn\'t valid for this project. This can happen if the user\'s token has been tampered with]: or if the user isn\'t for the project associated with this API key. (auth/invalid-user-token).'
69+
"Firebase: This user's credential isn't valid for this project. This can happen if the user's token has been tampered with]: or if the user isn't for the project associated with this API key. (auth/invalid-user-token)."
7070
);
7171
expect(mock.calls[0].request).to.eql(request);
7272
});
@@ -83,10 +83,12 @@ describe('deleteLinkedAccounts', () => {
8383

8484
it('should POST to the correct endpoint', async () => {
8585
const mock = mockEndpoint(Endpoint.SET_ACCOUNT_INFO, {
86-
providerUserInfo: [{
87-
providerId: ProviderId.GOOGLE,
88-
89-
}]
86+
providerUserInfo: [
87+
{
88+
providerId: ProviderId.GOOGLE,
89+
90+
}
91+
]
9092
});
9193

9294
const response = await deleteLinkedAccounts(mockAuth, request);
@@ -135,10 +137,12 @@ describe('getAccountInfo', () => {
135137

136138
it('should POST to the correct endpoint', async () => {
137139
const mock = mockEndpoint(Endpoint.GET_ACCOUNT_INFO, {
138-
users: [{
139-
displayName: 'my-name',
140-
141-
}]
140+
users: [
141+
{
142+
displayName: 'my-name',
143+
144+
}
145+
]
142146
});
143147

144148
const response = await getAccountInfo(mockAuth, request);
@@ -171,7 +175,7 @@ describe('getAccountInfo', () => {
171175

172176
await expect(getAccountInfo(mockAuth, request)).to.be.rejectedWith(
173177
FirebaseError,
174-
'Firebase: This user\'s credential isn\'t valid for this project. This can happen if the user\'s token has been tampered with]: or if the user isn\'t for the project associated with this API key. (auth/invalid-user-token).'
178+
"Firebase: This user's credential isn't valid for this project. This can happen if the user's token has been tampered with]: or if the user isn't for the project associated with this API key. (auth/invalid-user-token)."
175179
);
176180
expect(mock.calls[0].request).to.eql(request);
177181
});

packages-exp/auth-exp/src/api/account_management/email_and_password.test.ts

-2
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,6 @@ describe('resetPassword', () => {
7575
});
7676
});
7777

78-
7978
describe('updateEmailPassword', () => {
8079
const request = {
8180
idToken: 'id-token',
@@ -126,4 +125,3 @@ describe('updateEmailPassword', () => {
126125
expect(mock.calls[0].request).to.eql(request);
127126
});
128127
});
129-

packages-exp/auth-exp/src/api/account_management/mfa.test.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ describe('startEnrollPhoneMfa', () => {
7474

7575
await expect(startEnrollPhoneMfa(mockAuth, request)).to.be.rejectedWith(
7676
FirebaseError,
77-
'Firebase: This user\'s credential isn\'t valid for this project. This can happen if the user\'s token has been tampered with]: or if the user isn\'t for the project associated with this API key. (auth/invalid-user-token).'
77+
"Firebase: This user's credential isn't valid for this project. This can happen if the user's token has been tampered with]: or if the user isn't for the project associated with this API key. (auth/invalid-user-token)."
7878
);
7979
expect(mock.calls[0].request).to.eql(request);
8080
});
@@ -180,7 +180,7 @@ describe('withdrawMfa', () => {
180180

181181
await expect(withdrawMfa(mockAuth, request)).to.be.rejectedWith(
182182
FirebaseError,
183-
'Firebase: This user\'s credential isn\'t valid for this project. This can happen if the user\'s token has been tampered with]: or if the user isn\'t for the project associated with this API key. (auth/invalid-user-token).'
183+
"Firebase: This user's credential isn't valid for this project. This can happen if the user's token has been tampered with]: or if the user isn't for the project associated with this API key. (auth/invalid-user-token)."
184184
);
185185
expect(mock.calls[0].request).to.eql(request);
186186
});

packages-exp/auth-exp/src/api/authentication/email_and_password.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ interface GetOobCodeRequest {
6262
androidMinimumVersionCode?: string;
6363
canHandleCodeInApp?: boolean;
6464
dynamicLinkDomain?: string;
65-
tenantId?: string,
66-
targetProjectid?: string,
65+
tenantId?: string;
66+
targetProjectid?: string;
6767
}
6868

6969
export interface VerifyEmailRequest extends GetOobCodeRequest {

packages-exp/auth-exp/src/api/index.ts

+7-3
Original file line numberDiff line numberDiff line change
@@ -68,16 +68,20 @@ export async function performApiRequest<T, V>(
6868
};
6969
if (request) {
7070
if (method === HttpMethod.GET) {
71-
Object.assign(params, request);
71+
Object.assign(params, request);
7272
} else {
7373
body = {
7474
body: JSON.stringify(request)
7575
};
7676
}
7777
}
7878

79-
const queryString = Object.keys(params).map(key => `${encodeURIComponent(key)}=${encodeURIComponent(params[key])}`).join('&');
80-
79+
const queryString = Object.keys(params)
80+
.map(
81+
key => `${encodeURIComponent(key)}=${encodeURIComponent(params[key])}`
82+
)
83+
.join('&');
84+
8185
const response = await fetch(
8286
`${auth.config.apiScheme}://${auth.config.apiHost}${path}?${queryString}`,
8387
{

0 commit comments

Comments
 (0)