Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | 15x | import { DomainError } from '../../../shared/errors/domain-error';
/**
* Deliberately says nothing about *why* the code failed. Wrong digits, expired, never issued, too
* many attempts, and "no account with this e-mail" all raise this same error with this same
* message — otherwise the verify endpoints would answer a question the request endpoints refuse to
* answer, and become the account-enumeration oracle the flow is designed to avoid.
*/
export class InvalidVerificationCodeError extends DomainError {
constructor() {
super('Invalid or expired code');
}
}
|