Skip to content
This repository was archived by the owner on Mar 17, 2025. It is now read-only.

Commit 709fd75

Browse files
author
jacobawenger
committed
Added deprecation warning to $sendPasswordResetEmail()
1 parent 910b42b commit 709fd75

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.jshintrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
"forin": true,
1010
"indent": 2,
1111
"latedef": true,
12+
"node": true,
1213
"noempty": true,
1314
"nonbsp": true,
1415
"strict": true,

src/FirebaseAuth.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
$changePassword: this.changePassword.bind(this),
5353
$removeUser: this.removeUser.bind(this),
5454
$resetPassword: this.resetPassword.bind(this),
55-
$sendPasswordResetEmail: this.resetPassword.bind(this)
55+
$sendPasswordResetEmail: this.sendPasswordResetEmail.bind(this)
5656
};
5757

5858
return this._object;
@@ -269,6 +269,12 @@
269269
return deferred.promise;
270270
},
271271

272+
// Sends a password reset email to an email/password user. [DEPRECATED]
273+
sendPasswordResetEmail: function(emailOrCredentials) {
274+
console.warn("$sendPasswordResetEmail() has been deprecated in favor of the equivalent $resetPassword().");
275+
return this.resetPassword(emailOrCredentials);
276+
},
277+
272278
// Sends a password reset email to an email/password user.
273279
resetPassword: function(emailOrCredentials) {
274280
var deferred = this._q.defer();

0 commit comments

Comments
 (0)