private async Task ProccedMessageVerification(int userId, string email, bool isCorrect) { if (isCorrect) { await emailVerifierRepository.Delete(e => IsRequestedEmailVerifier(e, userId, email)); } else { EmailVerifies emailVerifier = emailVerifierRepository .GetWhere(e => IsRequestedEmailVerifier(e, userId, email)).FirstOrDefault(); emailVerifier.Attempts++; await emailVerifierRepository.Update(emailVerifier); } }
private async Task RemoveStorageVerification(EmailVerifies emailVerifier) { await emailVerifierRepository.Delete(e => e.UserId.Equals(emailVerifier.UserId)); }