public IActionResult Delete(string email) { var AuxUser = UserDataBase.GetUser(email); if (AuxUser == null) { return(NotFound()); } else if (!UserDataBase.DeleteUser(email)) { return(BadRequest()); } return(Ok()); }
public ActionResult <User> Get(string email) { try { var AuxUser = UserDataBase.GetUser(email).First(); if (AuxUser == null) { return(BadRequest()); } return(Ok(AuxUser)); } catch (InvalidOperationException) { return(NotFound()); } }
public void GetUser(long login) { activeUser = dataBase.GetUser(login); }