public async Task <Response> CreateResponseAsync() { List <KeyVm> userKeys; if (request.KeysId != null) { userKeys = await keysService.GetUserPublicKeysAsync(request.UserId, request.KeysId).ConfigureAwait(false); } else { userKeys = await keysService.GetUserPublicKeysAsync( request.UserId, request.NavigationTime.GetValueOrDefault(), request.Direction.GetValueOrDefault(true)).ConfigureAwait(false); } return(new KeysResponse(request.RequestId, userKeys)); }