From c8e2dd78b4bcaa0b340162801fb63562c000eae4 Mon Sep 17 00:00:00 2001 From: Ivan Semenov Date: Thu, 28 Feb 2019 19:23:35 +0300 Subject: [PATCH] [github] Pass correct exception from PR list loader Issue: IDEA-206881 --- .../pullrequest/data/GithubPullRequestsListLoaderImpl.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/github/src/org/jetbrains/plugins/github/pullrequest/data/GithubPullRequestsListLoaderImpl.kt b/plugins/github/src/org/jetbrains/plugins/github/pullrequest/data/GithubPullRequestsListLoaderImpl.kt index 6010c09e6493..c7d35350dfc7 100644 --- a/plugins/github/src/org/jetbrains/plugins/github/pullrequest/data/GithubPullRequestsListLoaderImpl.kt +++ b/plugins/github/src/org/jetbrains/plugins/github/pullrequest/data/GithubPullRequestsListLoaderImpl.kt @@ -26,6 +26,7 @@ import org.jetbrains.plugins.github.util.GithubAsyncUtil import org.jetbrains.plugins.github.util.NonReusableEmptyProgressIndicator import org.jetbrains.plugins.github.util.handleOnEdt import java.util.concurrent.CompletableFuture +import java.util.concurrent.CompletionException import java.util.concurrent.ScheduledFuture import java.util.concurrent.TimeUnit import javax.swing.ListModel @@ -94,7 +95,7 @@ internal class GithubPullRequestsListLoaderImpl(private val progressManager: Pro if (indicator.isCanceled) return@handleOnEdt when { error != null && !GithubAsyncUtil.isCancellation(error) -> { - this.error = error + this.error = if (error is CompletionException) error.cause!! else error } responsePage != null -> { listModelDelegate.add(responsePage.items)