@@ -345,7 +345,7 @@ export class AccountsServer {
345
345
throw new AccountsError ( 'User not found' ) ;
346
346
}
347
347
348
- const impersonatedUser = await this . db . findUserByUsername ( username ) ;
348
+ const impersonatedUser = await this . findUserByUsername ( username ) ;
349
349
if ( ! impersonatedUser ) {
350
350
throw new AccountsError ( `User ${ username } not found` ) ;
351
351
}
@@ -776,7 +776,7 @@ export class AccountsServer {
776
776
* @returns {Promise<void> } - Return a Promise.
777
777
*/
778
778
public async sendVerificationEmail ( address : string ) : Promise < void > {
779
- const user = await this . db . findUserByEmail ( address ) ;
779
+ const user = await this . findUserByEmail ( address ) ;
780
780
if ( ! user ) {
781
781
throw new AccountsError ( 'User not found' , { email : address } ) ;
782
782
}
@@ -813,7 +813,7 @@ export class AccountsServer {
813
813
* @returns {Promise<void> } - Return a Promise.
814
814
*/
815
815
public async sendResetPasswordEmail ( address : string ) : Promise < void > {
816
- const user = await this . db . findUserByEmail ( address ) ;
816
+ const user = await this . findUserByEmail ( address ) ;
817
817
if ( ! user ) {
818
818
throw new AccountsError ( 'User not found' , { email : address } ) ;
819
819
}
@@ -841,7 +841,7 @@ export class AccountsServer {
841
841
* @returns {Promise<void> } - Return a Promise.
842
842
*/
843
843
public async sendEnrollmentEmail ( address : string ) : Promise < void > {
844
- const user = await this . db . findUserByEmail ( address ) ;
844
+ const user = await this . findUserByEmail ( address ) ;
845
845
if ( ! user ) {
846
846
throw new AccountsError ( 'User not found' , { email : address } ) ;
847
847
}
0 commit comments