Index: editor/tools/plugins/com.google.dart.tools.update.core/src/com/google/dart/tools/update/core/internal/jobs/CheckForUpdatesJob.java |
=================================================================== |
--- editor/tools/plugins/com.google.dart.tools.update.core/src/com/google/dart/tools/update/core/internal/jobs/CheckForUpdatesJob.java (revision 9083) |
+++ editor/tools/plugins/com.google.dart.tools.update.core/src/com/google/dart/tools/update/core/internal/jobs/CheckForUpdatesJob.java (working copy) |
@@ -31,6 +31,7 @@ |
private final DownloadManager downloadManager; |
private Revision latest; |
+ private String message; |
/** |
* Create an instance. |
@@ -43,6 +44,15 @@ |
} |
/** |
+ * Get details in case an error occurred during check for updates. |
+ * |
+ * @return the message a displayable error message (or <code>null</code> if none was recorded) |
+ */ |
+ public String getErrorMessage() { |
+ return message; |
+ } |
+ |
+ /** |
* Get the latest available update. |
* |
* @return the latest update, or <code>null</code> if it has not been retrieved yet |
@@ -56,7 +66,8 @@ |
try { |
latest = downloadManager.getLatestRevision(); |
} catch (IOException e) { |
- return UpdateCore.createErrorStatus("Unable to get latest revision: " + e.getMessage()); //$NON-NLS-1$ |
+ message = "Unable to get latest revision."; |
+ UpdateCore.logError(message);//$NON-NLS-1$ |
} |
return Status.OK_STATUS; |
} |