|
311 | 311 |
|
312 | 312 | // Throw an error if they are trying to pass in separate string arguments |
313 | 313 | if (typeof credentials === "string") { |
314 | | - throw new Error("Passing in credentials to $createUser() as individual arguments has been removed in favor of a single credentials argument. See the AngularFire API reference for details."); |
| 314 | + throw new Error("$createUser() expects an object containing 'email' and 'password', but got a string."); |
315 | 315 | } |
316 | 316 |
|
317 | 317 | try { |
|
335 | 335 |
|
336 | 336 | // Throw an error if they are trying to pass in separate string arguments |
337 | 337 | if (typeof credentials === "string") { |
338 | | - throw new Error("Passing in credentials to $changePassword() as individual arguments has been removed in favor of a single credentials argument. See the AngularFire API reference for details."); |
| 338 | + throw new Error("$changePassword() expects an object containing 'email', 'oldPassword', and 'newPassword', but got a string."); |
339 | 339 | } |
340 | 340 |
|
341 | 341 | try { |
|
356 | 356 | */ |
357 | 357 | changeEmail: function(credentials) { |
358 | 358 | if (typeof this._ref.changeEmail !== 'function') { |
359 | | - throw new Error('$firebaseAuth.$changeEmail() requires Firebase version 2.1.0 or greater.'); |
| 359 | + throw new Error("$changeEmail() expects an object containing 'oldEmail', 'newEmail', and 'password', but got a string."); |
360 | 360 | } |
361 | 361 |
|
362 | 362 | var deferred = this._q.defer(); |
|
381 | 381 |
|
382 | 382 | // Throw an error if they are trying to pass in separate string arguments |
383 | 383 | if (typeof credentials === "string") { |
384 | | - throw new Error("Passing in credentials to $removeUser() as individual arguments has been removed in favor of a single credentials argument. See the AngularFire API reference for details."); |
| 384 | + throw new Error("$removeUser() expects an object containing 'email' and 'password', but got a string."); |
385 | 385 | } |
386 | 386 |
|
387 | 387 | try { |
|
406 | 406 |
|
407 | 407 | // Throw an error if they are trying to pass in a string argument |
408 | 408 | if (typeof credentials === "string") { |
409 | | - throw new Error("Passing in credentials to $resetPassword() as individual arguments has been removed in favor of a single credentials argument. See the AngularFire API reference for details."); |
| 409 | + throw new Error("$resetPassword() expects an object containing 'email', but got a string."); |
410 | 410 | } |
411 | 411 |
|
412 | 412 | try { |
|
0 commit comments