@@ -344,7 +344,7 @@ export class AccountsServer {
344
344
throw new AccountsError ( 'User not found' ) ;
345
345
}
346
346
347
- const impersonatedUser = await this . db . findUserByUsername ( username ) ;
347
+ const impersonatedUser = await this . findUserByUsername ( username ) ;
348
348
if ( ! impersonatedUser ) {
349
349
throw new AccountsError ( `User ${ username } not found` ) ;
350
350
}
@@ -772,7 +772,7 @@ export class AccountsServer {
772
772
* @returns {Promise<void> } - Return a Promise.
773
773
*/
774
774
public async sendVerificationEmail ( address : string ) : Promise < void > {
775
- const user = await this . db . findUserByEmail ( address ) ;
775
+ const user = await this . findUserByEmail ( address ) ;
776
776
if ( ! user ) {
777
777
throw new AccountsError ( 'User not found' , { email : address } ) ;
778
778
}
@@ -809,7 +809,7 @@ export class AccountsServer {
809
809
* @returns {Promise<void> } - Return a Promise.
810
810
*/
811
811
public async sendResetPasswordEmail ( address : string ) : Promise < void > {
812
- const user = await this . db . findUserByEmail ( address ) ;
812
+ const user = await this . findUserByEmail ( address ) ;
813
813
if ( ! user ) {
814
814
throw new AccountsError ( 'User not found' , { email : address } ) ;
815
815
}
@@ -837,7 +837,7 @@ export class AccountsServer {
837
837
* @returns {Promise<void> } - Return a Promise.
838
838
*/
839
839
public async sendEnrollmentEmail ( address : string ) : Promise < void > {
840
- const user = await this . db . findUserByEmail ( address ) ;
840
+ const user = await this . findUserByEmail ( address ) ;
841
841
if ( ! user ) {
842
842
throw new AccountsError ( 'User not found' , { email : address } ) ;
843
843
}
0 commit comments