using Models; using Endpoint; using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace LocalEndpoint { internal class ConnectionManager : IAccountManager { private Account userAccount = Constants.MAIN_USER_ACCOUNT; private string userPassword = Constants.MAIN_USER_PASSWORD; public Account? Login(string email, string password) { if (Constants.MAIN_USER_ACCOUNT.Email == email && Constants.MAIN_USER_PASSWORD == password) return Constants.MAIN_USER_ACCOUNT; return null; } public Account? Register(string email, string username, string password) { if (email == null || username == null || password == null) return null; userAccount = new Account(new User(Constants.DEFAULT_ACCOUNT_IMAGE, username), email); userPassword = password; return userAccount; } } }