Skip to content

Commit a1dc176

Browse files
authored
docs
Signed-off-by: Manuel <[email protected]>
1 parent 7d436c9 commit a1dc176

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/cloud-code/Parse.Cloud.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -350,7 +350,6 @@ ParseCloud.afterLogout = function (handler) {
350350
};
351351

352352
/**
353-
*
354353
* Registers the before password reset request function.
355354
*
356355
* **Available in Cloud Code only.**
@@ -359,13 +358,14 @@ ParseCloud.afterLogout = function (handler) {
359358
* before the reset email is sent. It is triggered after the user is found
360359
* by email, but before the reset token is generated and the email is sent.
361360
*
361+
* Code example:
362+
*
362363
* ```
363-
* Parse.Cloud.beforePasswordResetRequest((request) => {
364-
* // Validate email or user properties
365-
* if (!request.object.get('emailVerified')) {
366-
* throw new Parse.Error(Parse.Error.EMAIL_NOT_FOUND, 'Email not verified');
364+
* Parse.Cloud.beforePasswordResetRequest(request => {
365+
* if (request.object.get('banned')) {
366+
* throw new Parse.Error(Parse.Error.EMAIL_NOT_FOUND, 'User is banned.');
367367
* }
368-
* })
368+
* });
369369
*
370370
* ```
371371
*

0 commit comments

Comments
 (0)