Ejemplo n.º 1
0
        /// <inheritdoc />
        /// <summary>
        /// Return access token
        /// </summary>
        /// <returns></returns>
        public async Task GetAccessTokenResponse()
        {
            try
            {
                _accessTokenResponse.AccessToken = await _httpRequest.GetAccessToken(UserInfoDictionary);

                _accessTokenResponse.Success = true;
            }
            catch (HttpRequestException)
            {
                _accessTokenResponse.Success = false;
                ShowConnectionLostDialog();
            }
            catch (UnauthorizedAccessException)
            {
                _accessTokenResponse.Success = false;
                ClearUserInfo();
                ShowErrorDialog();
            }
        }