Changes in validator

This commit is contained in:
batgo6o
2021-03-15 16:38:02 +02:00
parent cbb3b404c0
commit 3b673f153e
2 changed files with 6 additions and 38 deletions

View File

@@ -1,36 +0,0 @@
using Models;
using Models.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace Business.Business.UserManagment
{
public class CredentialChecker
{
private LuminousContext context;
public bool CheckIfUserIsCreated()
{
using (context = new LuminousContext())
{
if (context.User.ToList().Any())
{
return true;
}
return false;
}
}
public bool CheckPassword(string Password)
{
using (context = new LuminousContext())
{
if (context.User.ToList().Exists(user => user.Password == Password))
{
return true;
}
return false;
}
}
}
}