Frequently Used Methods
Frequently Used Methods
Frequently Used Methods
Frequently Used Methods
public async Task <Account> GetAccount([FromUri] string email = null, [FromUri] string id = null) { var account = new Account(); if (email.IsNullOrWhiteSpace() && id.IsNullOrWhiteSpace()) { throw new ArgumentNullException(nameof(email)); } if (email != null) { return(await _accountsService.GetAccountByEmail(email)); } var userIdAsGuid = Guid.Parse(id); return(await _accountsService.GetAccountById(userIdAsGuid)); }