Skip to content

Commit c427ca9

Browse files
committed
changed mutation names in test also
1 parent 5bae516 commit c427ca9

File tree

2 files changed

+22
-22
lines changed

2 files changed

+22
-22
lines changed

spec/ParseGraphQLServer.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7148,7 +7148,7 @@ describe('ParseGraphQLServer', () => {
71487148
},
71497149
},
71507150
});
7151-
console.log(result);
7151+
71527152
expect(result.data.logIn.clientMutationId).toEqual(clientMutationId);
71537153
expect(result.data.logIn.viewer.sessionToken).toBeDefined();
71547154
expect(typeof result.data.logIn.viewer.sessionToken).toBe('string');

src/GraphQL/loaders/usersMutations.js

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -215,10 +215,10 @@ const load = parseGraphQLSchema => {
215215
parseGraphQLSchema.addGraphQLType(logOutMutation.type, true, true);
216216
parseGraphQLSchema.addGraphQLMutation('logOut', logOutMutation, true, true);
217217

218-
const requestResetPasswordMutation = mutationWithClientMutationId({
219-
name: 'RequestResetPassword',
218+
const resetPasswordMutation = mutationWithClientMutationId({
219+
name: 'ResetPassword',
220220
description:
221-
'The requestResetPassword mutation can be used to reset the password of an existing user.',
221+
'The resetPassword mutation can be used to reset the password of an existing user.',
222222
inputFields: {
223223
email: {
224224
descriptions: 'Email of the user that should receive the reset email',
@@ -247,23 +247,14 @@ const load = parseGraphQLSchema => {
247247
},
248248
});
249249

250-
parseGraphQLSchema.addGraphQLType(
251-
requestResetPasswordMutation.args.input.type.ofType,
252-
true,
253-
true
254-
);
255-
parseGraphQLSchema.addGraphQLType(requestResetPasswordMutation.type, true, true);
256-
parseGraphQLSchema.addGraphQLMutation(
257-
'requestResetPassword',
258-
requestResetPasswordMutation,
259-
true,
260-
true
261-
);
250+
parseGraphQLSchema.addGraphQLType(resetPasswordMutation.args.input.type.ofType, true, true);
251+
parseGraphQLSchema.addGraphQLType(resetPasswordMutation.type, true, true);
252+
parseGraphQLSchema.addGraphQLMutation('resetPassword', resetPasswordMutation, true, true);
262253

263-
const resetPasswordMutation = mutationWithClientMutationId({
264-
name: 'ResetPassword',
254+
const confirmResetPasswordMutation = mutationWithClientMutationId({
255+
name: 'ConfirmResetPassword',
265256
description:
266-
'The resetPassword mutation can be used to reset the password of an existing user.',
257+
'The confirmResetPassword mutation can be used to reset the password of an existing user.',
267258
inputFields: {
268259
username: {
269260
descriptions: 'Username of the user that have received the reset email',
@@ -302,9 +293,18 @@ const load = parseGraphQLSchema => {
302293
},
303294
});
304295

305-
parseGraphQLSchema.addGraphQLType(resetPasswordMutation.args.input.type.ofType, true, true);
306-
parseGraphQLSchema.addGraphQLType(resetPasswordMutation.type, true, true);
307-
parseGraphQLSchema.addGraphQLMutation('resetPassword', resetPasswordMutation, true, true);
296+
parseGraphQLSchema.addGraphQLType(
297+
confirmResetPasswordMutation.args.input.type.ofType,
298+
true,
299+
true
300+
);
301+
parseGraphQLSchema.addGraphQLType(confirmResetPasswordMutation.type, true, true);
302+
parseGraphQLSchema.addGraphQLMutation(
303+
'confirmResetPassword',
304+
confirmResetPasswordMutation,
305+
true,
306+
true
307+
);
308308

309309
const sendVerificationEmailMutation = mutationWithClientMutationId({
310310
name: 'SendVerificationEmail',

0 commit comments

Comments
 (0)