public async Task <List <IUserInfo> > GetByIPAddress(Guid siteGuid, string ipv4Address, CancellationToken cancellationToken = default(CancellationToken)) { cancellationToken.ThrowIfCancellationRequested(); List <IUserInfo> userList = new List <IUserInfo>(); using (DbDataReader reader = await dbUserLocation.GetUsersByIPAddress(siteGuid, ipv4Address)) { while (reader.Read()) { UserInfo user = new UserInfo(); user.LoadFromReader(reader); userList.Add(user); } } return(userList); }
public async Task<List<IUserInfo>> GetByIPAddress(Guid siteGuid, string ipv4Address) { List<IUserInfo> userList = new List<IUserInfo>(); using (DbDataReader reader = await dbUserLocation.GetUsersByIPAddress(siteGuid, ipv4Address)) { while (reader.Read()) { UserInfo user = new UserInfo(); user.LoadFromReader(reader); userList.Add(user); } } return userList; }
public async Task <List <IUserInfo> > GetByIPAddress(Guid siteGuid, string ipv4Address) { List <IUserInfo> userList = new List <IUserInfo>(); if (multiTenantOptions.UseRelatedSitesMode) { siteGuid = Guid.Empty; } using (DbDataReader reader = await dbUserLocation.GetUsersByIPAddress(siteGuid, ipv4Address)) { while (reader.Read()) { UserInfo user = new UserInfo(); user.LoadFromReader(reader); userList.Add(user); } } return(userList); }